Gay people don't need treatment so any comparison there is flawed.
Also 'trans' is not just one thing so we can't judge all of them the same way.
Teenage girls wanting to be boys is mostly them running away from being a girl in a sexist society. Girls used to suffer through the adjustment and become women, but now are offered a way to run away from reality. Some may have a real body dysphoria thing going on and that would be mental illness. So two types there.
It's less clear what teenage boys get out of it - aside from getting to see naked teenage girls in changing rooms - but often I notice a parent in the background explaining that 'she' always knew 'she' was a girl from the age of 2.
Some boys may struggle with puberty, but it's not a big deal for us as it is for girls.
There may be some adult men who find their own genitals distressing, but they must be rare as most seem eager to talk about their penis and show it to women. Still those who do will have a mental illness which can probably be treated with therapy.
That means at least two significantly types of trans-identifying men. Probably several more as some are gay and looking for a relationship with a man who will treat them as a woman. Not easy since most gay men would find even the attempt to look like a woman a deal breaker.
Then there are men who find the thought of having a 'female' body and dressing it up, to be arousing. So a fetish rather than a mental illness and probably not distressing at all.
So a lifestyle choice for many or a fetish and a mental illness for what is probably a tiny subset of trans.