The Day of Atonement was a festival to be celebrated by the Hebrews and Israelites, mandated by the biblical books of Leviticus and Numbers (both found in the Law). This day designated a special sabbath rest and was to be celebrated on the tenth day of the seventh month of the Hebrew calendar; ten days after the Feast of Trumpets. On this day the High Priest of the Levitical Priesthood would make several special offerings to serve as an annual atonement for the Israelite's sins.
The Day of Atonement was to be practiced on the tenth day of the seventh month. The Day of the Atonement was to be both a sabbath rest and a day of fasting. Not fasting was met with strict punishment of being cut off from the rest of Israel, while those who did labor would be destroyed by God. As on other feast days a sacred assembly would be called to order.
The most important regulations concerning the day were about the sacrifices and the process of giving them to the Lord.
The High Priest of Israel at the time, Aaron, had four sons who could possibly be successors. Since they were all Levites all of Aaron's sons were priests, including two named Nadab and Abihu.Apparently these two sons both burned fire in the Tabernacle's holy of holies, but did so without permission by law. Thus these two sons were both killed by the fire that they burned as an offering to God.
A short time after this God spoke to Moses and gave Aaron regulations for a Day of Atonement and the procedure that he must follow. God told Aaron that he would not be allowed to enter into the presence of the Ark of the Covenant whenever he pleased. This was a result of the wrongful fire burning that was done by his sons. Through Moses God gave Aaron specific rules for entering the Holy Place and he would only be allowed on the special Day of Atonement. According to the Book of Exodus, Aaron was commanded to make yearly atonement. Prior to the Day of Atonement Aaron was to sacrifice on an altar located directly outside the special room.
There would've been a short period of time between this command and the formal establishment of a legal day of atonement.