The entire "Ode to a Nightingale" is based on a poetic conceit, sometimes overlooked. The nightingale Keats hears is singing the same song that nightingales have sung since time immemorial, so Keats imagines that the bird is immortal. He would like to be able to join it, because it seems that if he could escape into this bird's world he could escape permanently from the world
Where but to think is to be full of sorrow
And leaden-eyed despairs;
Where beauty cannot keep her lustrous eyes,
Or new Love pine at them beyond tomorrow.
Keats pursues the notion of the nightingle's immortality until he has followed the bird all the way back in his imagination to biblical times, and even beyond that into a Never-Never Land or "faery lands forlorn." (They are forlorn because nobody believes in them anymore.) In Keats's poetry many things remind him of his own mortality. He is haunted by the fear of death and by his desire to escape from his morbid thoughts. Even a bird singing its familiar song in the nearby bushes reminds him of his obsession with death and the desire to escape. (There is a striking similarity between Keats's nightingale and Edgar Allan Poe's raven.)
Keats begins by regarding the nightingale as an ordinary bird and then, becoming fixated on its song, imagines it to be a supernatural creature that could actually transport him out of the world where he feels so miserable most of the time because he is facing death and can never possess the girl he loves. He actually only lived to be twenty-six and died in Italy, where he had gone to live in the hope that the warmer climate might save his life.