The exact manner of <PERSON>' death did not appear to be significant to early authors of the myth. In fact, even though both <PERSON> and <PERSON> mention the hero eventually finding his place amongst the gods1, neither explain how he achieved divinity. It seems the task of constructing a tale explaining <PERSON>' unique and somewhat bizare2 status as "hero god" was daunting, even to the likes of <PERSON> and <PERSON>.
Yet, although <PERSON> may not have been a protagonist in the works of the epic poets, in the 5th century BCE he was truly a panhellenic hero. The story of his death and deification was now an important one, one that could not remain untold. Audiences were already aware that <PERSON> had cheated death more than once, and that he would eventually ascent to Olympus. All that remained was an elaborate death scene, one that would be majestic enough to match the status of the hero and perhaps theologically significant enough to explain the transition from man to god.
Death by fire may seem like an excruciating way to go, however, it really is the most fitting choice. Before attempting to explain why I'd like to provide some context by quoting parts of the story as told by <PERSON> in Trachiniae:
<PERSON>
Now... do you know <PERSON>' sacred mountain Oeta?
<PERSON>
Yes. I have often sacrificed upon it.
<PERSON>
That is the place where you must carry me
with your own hands, and with what friends you choose.
There hew the wood of deeply-rooted oaks
and slash the trunks of wild male olive trees,
placing my body on a pyre made from them;
then take a brightly blazing torch of pine
and light the pyre. And do not moan and weep,
for if you are my son you will perform this
without a sigh or tear. If not, my curse,
even when I am dead, will weigh upon you.
Sophocles, Women of Trachis. Translation by <PERSON>
<PERSON> reluctantly agrees and constructs the pyre, and then places his father on it:
<PERSON>
At last you speak well! Now perform this favor swiftly, my child, and place me on the pyre before the stinging spasm comes again. Make haste and lift me. 351
Now I feel release from troubles, for my final end is here.
<PERSON>
Nothing prevents fulfillment of these deeds, since you command it and compel us, father
The first question we must ask is if <PERSON>' death is in accordance with funerary customs of the era, as his deification would be even more inexplicable if his death was somehow sacrilegious. Although cremation had gone out of style in most parts of Greece, it was not entirely abandoned and was still the preferred practice in Athens. Furthermore - and perhaps more importantly - cremation was strongly associated with the Heroic Age. Even if it wasn't the favourite practice of the era, we can't ignore how the tale of <PERSON>' death parallels the deaths of the heroes of the Trojan War3.
Still, the hero's death is gruesome. He is burned alive after all. However, even though <PERSON> knows that his suffering will eventually end5, it is established in the tale that the pain from the poison is, for lack of a better word, unbearable. Out of context, his death appears dreadful. Considering the alternative, though, we may even say it's liberating. In some versions of the myth, the poison is said to slowly burn the hero's skin, making his death even more fitting. It doesn't add to the pain, it only accelerates the inevitable.
As for theological symbolisms, the most obvious one is that of sacrifice. <PERSON> specifically chooses Oeta - a mountain sacred to <PERSON> - as the scene of his death and provides elaborate instructions for the construction of the pyre. Both the location and the complexity of the pyre favour a ritualistic interpretation, a last offering of <PERSON> to the glory of <PERSON>.
Or perhaps the ritual is one of purification, one that intends to separate (or even liberate) the divine from the corporeal. This wouldn't be a new idea, as the notion of burning mortality away also appears in the story of <PERSON>:
When she had so spoken, she took the child in her fragrant bosom with her divine hands: and his mother was glad in her heart. So the goddess nursed in the palace Demophoon, wise <PERSON>' goodly son whom well-girded <PERSON> bare. 660