Hi,
According to 'Modern English Usage' by Fowler, an indirect question is the grammarian's name for a modification of what was originally a question.
I don't see an 'original question' at the start of this exchange.
It sems to me that the conversation could be something like
A: Tom is my name. (This is a statement, not a question.)
B (addressing C): I didn't hear him. What did he say was his name?
C: He said Tom was his name. (or He said his name was Tom, I'm not suggesting that is wrong or uncommon.)
Best wishes, Clive