This deals with a well-known prophecy that Elijah would come again. The prophecy did not mean that there was going to be a reincarnation of the ancient prophet. Luke 1:17 clarifies when the angel says to Zacharias regarding the birth of John the Baptist, "It is he who will go as a forerunner before Him in the spirit and power of Elijah, to turn the hearts of the fathers back to the children…". The angel quotes the prophecy in Malachi 4:5-6 and attributes its fulfillment in John the Baptist. Jesus confirms that in Matthew 11:14 when He says, "And if you are willing to accept it, John himself is Elijah who was to come."
It is true that John the Baptist denied being Elijah (John 1:21). However, he denied being Elijah because he realized the question was about a literal, reincarnated Elijah. He doubtlessly also realized that the questioning of the priests and Levites originated from unbelief, not sincere faith.