There is no "mechanism of any file indexing" in Linux kernel.
There are some user-space tools such as `locate` (+updatedb), KDE Nepomuk and similar.
Now, filesystems may have use some clever techniques to store directory indexes, but it has nothing to do with locate & friends - it is merely a filesystem implementation detail, and it depends on what filesystem is being used.