Khadgar is already an old man, and dealing with the consequences of Medivh’s curse that physically aged him dramatically during the events of the Orc Wars, and that was decades ago!
He turned himself into pure arcane energy, and the Dark Heart feeds off of Arcane energy and converts it into Void energy. When Khadgar came back, he was in raven form, an ability nominally tied to Atiesh, his staff that he inherited from the previous Guardian, that was also disintegrated and absorbed by Xal’atath.
He created a new spell, on the fly, and was transmuted into sentient arcane energy and trapped within the Dark Heart, slowly being drained and converted into Void energy, for weeks, if not months, before Alleria released him by damaging the Dark Heart. And we have no idea if time flows at the same speed, or even in the same direction, within the Dark Heart.
Odds are, chunks of Khadgar are missing and since he created and cast that spell on the fly, when he transformed back, parts of him were missing, and parts of other arcane materials absorbed by the Dark Heart were either transposed or fused into him as well. That he’s able to be coherent at all is amazing.
The running theories are that Khadgar has had his brain, which is a lump of fatty salt running on less energy than a battery can provide, accidentally re-wired by the process of discorporating, being partially eaten and then rebuilt on the fly, and it is going to take him time to re-learn how to do what he once did, hence why he’s recovering in the wheelchair. He might even be whole, but his whole existence was torn apart, scrambled and pushed back together without any way to ensure his safety in the process.
Like somebody who had a traumatic brain injury, it takes time, and with his pre-existing symptoms (artificially aged, already quite old in the current timeline, suffered some pretty hideous hits while fighting Xal’atath before Dalaran become rubble, the fact we got the Dadghar back at all is a miracle.