As well as providing a (largely ineffective) extra layer of insulation, it is also a signal when frightened to make you look bigger to deter an attacker (again, not very effective with humans, but quite effective if you're covered in hair - as you could see if you ever see a spooked cat).