My understanding is that treason is specifically action undertaken to undermine / destroy the British State. I doubt if the actions of a few misguided British citizens electing to fight 'for' Afghanistan could ever present any threat whatsoever to the British State. Therefore, you'd have a hard job making a treason charge stick.
Perhaps they've read EM Forster of Hornblower fame:
"Given the choice of betraying my friend or my country, I hope I'd have the courage to betray my country".
Personally, I'd deny them the right of re-entry to the UK if they survive. If they want an Islamic State, then by all means go and stay in one, but leave us alone.
The unfortunate thing is that we are making such a pig's ear of the propaganda war and there are 1 Billion subscribers to this particular superstition who will feel their loyalties strained. (For the sake of fairness, I regard Islam as no better or worse than the christian superstition: All of this mumbo-jumbo has a hell of a lot to answer for).