Masks are developed from hunting. When the hunters were trying to get closer to their pray they dressed in hides and furs from the animals they were hunting. It was not only the looks and the scents from the hunters that helped them to get closer. They also copied the movements of the animals. That led them to become better hunters as well when they got training from imitating animals.
One of many explanations to the birth of theatre has to do with the lust to narrate. According to the Norwegian theatre professor Jon Nygaard we can find remote, pre-stone age cultures today, where religion or benefits had nothing to do with the development of theatre. They built theatre on the lust for narrating and playing a role.
And as the hunters got better in imitating animals, they developed it into dances and theatrical sketches using the masks to tell the story about the hunt. Later the hunter also got his mask when narrating the hunting stories. And here the first human masks started to develop. We may find these scenes in many petroglyphs from the Stone Age.
Masks were also used in religious rites and ceremonies for good hunting. We are now talking about early totem religions. In other words religions that are not begging a God to fulfill their will, but who are forcing their God, or Gods, to obey their will, it may be a good hunt or later a good harvest. These rituals were festive and involved the whole town or village.The origins from the hunt may also be the reason why there never have been any women anywhere in any tradition conventionally wearing masks, at least not according to Franca Rame. There have been and are a lot of female masks but traditionally they have all been used by men. It is first now since the twelfth century in the western world that woman has started using masks (See HERE).