These are all variants on the conditional mood. As a general rule, the "would" statement is known as the "conditional perfect", and can only be used in the clause that describes the consequence, not the one that sets up the condition (i.e. "If I would" is always incorrect).
A short breakdown of the examples, to the best of my knowledge:
1 is incorrect due to mixed tenses. "I would do" is present tense; "had I been" is past.
2 is correct: the tenses match (both past). The removal of "if" and the swapping of the order to "had I" in the second clause is a conditional inversion.
3 is also correct: Here, "were" is being used in a form known as the "present unreal conditional".
4: Correct; "were" is also used for the past unreal conditional (so again, the tenses match)
5&6: both incorrect; "would I be him" would only work in the form of a question, and not as part of the conditional statement: "If I changed into his clothes, would I be him?"
7&8: Same as in 5&6, only framed in the past tense (so the start would be "If I had changed[...]")
9-12 are all incorrect as the conditional perfect ("would[...]") cannot be used in an "if" clause, as mentioned at the start.