How? You might ask. Well, I Corinthians 15 gives us all the information we need to figure it out! We are told there that Christ is the first one who defeated death and received an imperishable body. Furthermore, we are told that no one can go into eternity in perishable flesh and blood inherited from Adam. All born of Adam must die and/or be transformed into a new body following after the model of Christ in order to enter eternity with God. The old cannot inherit the new.
That produces a problem with the biblical record when one remembers the stories of Enoch and Elijah. They were taken by God to be with him while they were still alive in Adamic flesh, before Christ arose. Therefore, according to I Corinthians 15, they are not prepared for, nor can they enter into eternity until they put off their old bodies and rise in new ones untainted by Adam's fall. Somehow, either by an transformation akin to the Rapture of the Church (which not revealed in the Word), or by returning to earth and going through "normal" processes, Enoch and Elijah have got to be transformed.
We have known that Elijah is in the mix forever, but the identity of the other witness has caused incredible speculation in the church. It really did not need to, for the Apostle Paul told us what we needed to know in order to identify both of them conclusively. Enoch and Elijah may have been enjoying the last few thousand years in the presence of God well enough, but they can't go into eternity the way they are. For their own good, and for the good of the Jews alive during Daniel's 70th week, those guys need to come back to earth, and then, they need to die!