Taken from Huffington Post:
Eating hair is common in animals in their grooming process and they normally create Hair Balls which are either vomited up (those of you with cats see this all of the time) or they pass through the intestine and come out through defecation, Eating hair is part of a neurosis found in some people who will have the same problem as in other mammals. It is interesting to note that it does happen with humans.