For it is said that after the departure of the Valar there was silence, and for an age Iluvatar sat alone in thought. Then he spoke and said: 'Behold I love the earth, which shall be a mansion for the Quendi and the Atani! But the Quendi shall be the fairest of all earthly creatures, and they shall have and shall conceive and bring forth more beauty than all my Children; and they shall have the greater bliss in this world. But to the Atani I will give a new gift.' Therefore he willed that the hearts of Men should seek beyond the world and should find no rest therein; but they should have a virtue to shape their life, amid the powers and chances of the world, beyond the Music of the Ainur, which is as fate to all things else; and of their operation everything should be, in form and deed, completed, and the world fulfilled unto the last and smallest.
But Iluvatar knew that Men, being set amid the turmoils of the powers of the world, would stray often, and would not use their gifts in harmony; and he said: 'These too in their time shall find that all that they do redounds at the end only to the glory of my work.' Yet the Elves believe that Men are often a grief to Manwe, who knows most of the mind of Iluvatar; for it seems to the Elves that Men resemble Melkor most of all the Ainur, although he has ever feared and hated them, even those that served him.
It is one with this gift of freedom that the children of Men dwell only a short space in the world alive, and are not bound to it, and depart soon whither the Elves know not. Whereas the Elves remain until the end of days, and their love of the Earth and all the world is more single and more poignant therefore, and as the years lengthen ever more sorrowful. For the Elves die not till the world dies, unless they are slain or waste in grief (and to both these seeming deaths they are subject); neither does age subdue their strength, unless one grow weary of ten thousand centuries; and dying they are gathered to the halls of Mandos in Valinor, whence they may in time return. But the sons of Men die indeed, and leave the world; wherefore they are called Guests, or the Strangers. Death is their fate, the gift of Iluvatar, which as Time wears even the Powers shall envy. But Melkor has cast his shadow upon it, and confounded it with darkness, and brought forth evil out of good, and fear out of hope. Yet of old the Valar declared to the Elves in Valinor that Men shall join in the Second Music of Ainur; whereas Iluvatar has not revealed what he purposes for the Elves after the World's end, and Melkor has not discovered it. --The Silmarillion, J.R.R. Tolkien