Brachylog, 9 bytes
⟦kpiᶠ≠ᵐhᵐ This is a generator that outputs one derangement of [0, …, n-1] given n.
If we wrap it in a ᶠ - findall metapredicate, we get all possible generations of derangements by the generator.
###Explanation
Explanation
⟦ The range [0, …, Input] k Remove the last element p Take a permutation of the range [0, …, Input - 1] iᶠ Take all pair of Element-index: [[Elem0, 0],…,[ElemN-1, N-1]] ≠ᵐ Each pair must contain different values hᵐ The output is the head of each pair