Indexes, like tables, are persisted in data files on disk. 8kB blocks that are used get loaded into cache and remain there until the space is needed for something else. If the cache is big enough and the index is used often enough, it will stay cached.