This is all down to static electricity.
Inside the Van de Graaff generator, there is a rubber band and rollers. As they are electrically insulated, when the motor turns they rub together and electrons are 'knocked' off causing a positive charge.
In order to try and reach an equilibrium, electrons from the dome (and anything touching it) move to the positively charged rubber band causing it to slowly gain a positive charge.
If you are also touching the dome, you will slowly become positively charged including each of your hairs. As like charges repel, and hair is very light, they will try and get as far away from each other as possible, causing them to stand up.