It seems that the claim that he "lived as a woman" might have been an attempt to destroy his reputation and justify his assassination.
From the article (it's archived in the usual place):
Elagabalus has been given female pronouns on the basis of classical texts that claim he asked to be called “lady” - but historians believe these accounts may simply have been a typical Roman attempt at character assassination.
This pronoun choice is based on the account of Roman chronicler Cassius Dio, who claims that Elagabalus was “termed wife, mistress and queen”, told one lover “‘Call me not Lord, for I am a Lady’,” and even asked for female genitalia to be fashioned for him.
However, these claims were written by a chronicler who served the emperor Severus Alexander, who took the throne following the assassination of Elagabalus, and the accounts use his reputedly deviant behaviour as a justification for this political murder.
Andrew Wallace-Hadrill, a Cambridge classics professor, said: “The Romans didn’t have our idea of ‘trans’ as a category, but they used accusations of sexual behaviour ‘as a woman’ as one of the worst insults against men.”