The theory of Men is that there exists a special, magical route that only the Elves know how to follow:
[T]he loremasters of Men said that a Straight Road must still be, for those that were permitted to find it. And they taught that, while the new world fell away, the old road and the path of the memory of the West still went on, as it were a mighty bridge invisible that passed through the air of breath and of flight (which were bent now as the world was bent), and traversed Ilmen which flesh unaided cannot endure, until it came to Tol Eressëa, the Lonely Isle, and maybe even beyond, to Valinor
The Silmarillion IV Akallabêth
However, it's never made clear exactly how this works; whether it's truly a magical heading that only the Elves know, or whether it's a property of their ships, or whether the Valar themselves literally pluck permitted ships out of the sea.
Regardless of exactly how they do it, it's beyond question that the Elves are really going back to the Undying Lands; from Tolkien's Letters, for example:
Only the 'immortals', the lingering Elves, may still if they will, wearying of the circle of the world, take ship and find the 'straight way', and come to the ancient or True West, and be at peace.
The Letters of J.R.R. Tolkien 131: To Milton Waldman. 1951