Iah

Iah ( Egyptian: "jˁḥ", Coptic ) is a minor ancient Egyptian moon god who eventually evolves into Khonsu. Iah is said to be a god of both time and fertility. He is most notable for creating the ancient lunar calendar. The word "jˁḥ" simply means "moon". It is also transliterated as "Yah", Yah(w), "Jah", "Jah(w)", "Joh" or "Aah".
5 Day Myth.
In an ancient Egyptian myth, sun god Ra has cursed goddess Nut so that she can not have birth on any of the 360 days of the year. The wisdom god Thoth devised a plan that involved challenging A'ah to a game of Senet. Thoth outsmarted A'ah and won enough moonlight to add 5 days to the year. Since these extra days were not cursed, Nut was able to birth a god on each of these days; Isis, Osiris, Nephthys, and Horus. Due to the loss of moonlight, the moon was unable to shine continuously and was forced to periodically dim in order to recuperate. Thus creating the phases of the moon.