Malachi was a contemporary of Nehemiah.
Malachi was written to the Israelites who were allowed to return to Israel from the Babylonian captivity under the Decree of Cyrus. Malachi addresses some key factors in the lives of these exiles who had returned to their homeland.
The Priesthood had become corrupt. The people became discouraged and rebelled against the Law of YeHoVaH. The people lost faith in YeHoVaH’s ways of living and felt that YeHoVaH was unjust.
The people became hearers, but not doers, and only went through the religious motions. Malachi was written to encourage the people, to give answers to the questions the people had, to promise them that YeHoVaH would return to them when they returned to Him, and to warn the Priests and the people of the dangers or curses they faced if they did not return to YeHoVaH.
Malachi also announces the coming of John the Baptist and the coming of Messiah Yeshua.