Can we say ...
"Do you know who is he?"
To me, it sounds very unnatural and grammatically incorrect. Though, I think we can say ...
"Do you know? Who is he?"
in conversation.
Is that right?
You have it right. As a single question, we would write:
Do you know who he is? (not, Do you know
who is he?)
However, the way you have punctuated these six words makes the wording acceptable in your second example. The first question ("Do you know?") is a lead-in to the second ("Who is he?").
When written that way, I imagine the speaker being rather excited. Perhaps there is a lot of buzz in the street as a celebrity is walking by. Someone might excitedly say to a friend, "Do you know? Who is he?"
I think in a more calm and collected state of mind, the question order is likely to be reversed:
Who is he? Do you know?
You might try thinking of the pattern you ask about as follows:
Do you know {interrogative word} {assertion}?
The clause that states the {assertion} uses normal word-order, subject...verb.
Do you know who {he is} ?
Do you know when {the train arrives}?
Do you know why {the library is closed today}?
Do you know where {my car keys went}?
Do you know how {this knot is tied}?
[1] Do you know [who is he]?
[2] Do you know [who he is]?
The subject-auxiliary inversion in [1] is wrong in most varieties of English, but [2] is fine.
The bracketed element is a subordinate interrogative clause (indirect question). Unlike main clause interrogatives, there is normally no inversion in subordinate interrogatives.
The meaning can be glossed as: “Do you know the answer to the question “Who is he?”’