In a direct question we ask What is it? or What is the difference? or What is the difference between A and B?
But when we change it back to an indirect question we rarely keep the verb in the same position. Instead we say things like I asked him what it was or I wonder what it is or I don't know what it is.
I don't know what is it is grammatically defensible but sounds like something a non-native speaker would say. I would only say it this way if it was two separate sentences ("I don't know - what is it?"). Perhaps with a noun rather than a pronoun it is less unidiomatic but it is still an unusual wording (I don't know what is the difference) - we might use it if we were emphasising the word "what".
We would normally say either I've never understood what the difference is between A and B or I've never understood what the difference between A and B is.
You can also miss out both "what" and the copula, and say "I've never understood the difference between A and B".