I've had that top of the head burning feeling before and went to the doctor about it and the doctor said it was a condition known as occipital neuralgia which affects the nerves that extend from the spinal cord to the scalp and can create sensations of burning on top of your head.
There's not too much you can do about it other than wait it out and within a day or two the burning sensation should go away.
I sometime has a shocking feeling as well as the burning feeling on the top of my head and that was normal as well and nothing the doctor nor I could do about it.
It's not harmful and should go away within a day or two even though it's painful.
Sinus pressure is also sometimes another cause of a burning sensation on top of your head so if you suffer from sinus infections then treating that sinus infection should cure the burning sensation on your head.