I'm just going to quote Raymond Chen's explanation here:
This feature has been around since Windows 95. If the target of a
shortcut no longer exists, the shell tries to resolve the shortcut;
i.e., find the object, wherever it ended up moving to. As I explained
several months before the question was posted, the algorithm used
by the shell varies depending on the operating system and the file
system and your domain policies. Possibly also the phase of the moon,
one can never be sure.
It's not that Explorer actually keeps track of the files as they move
around, just in case you had a shortcut to them. Rather, the shortcut
remembers enough information about the file so that if the file moves,
Explorer can try looking for it.
The fact that shortcuts can resolve targets means that shortcuts are a
handy tool for keeping track of files that might move around. If you
want to keep track of a file, you can just create a shortcut to it
(you don't even need to save it in a file), and when it comes time to
find the file, you just resolve the shortcut.
Be sure to also read the linked Windows Confidential article for more details, especially regarding NT's Distributed Link Tracking Service.