A thesaurus is a book that lists words and their synonyms to help find alternative words. It can be used to replace nouns like "baby" with "infant" or "child", verbs like "walked" with "strolled" or "ambled", adjectives like "happy" with "merry" or "gleeful", and adverbs like "eagerly" with "excitedly" or "avidly". The document provides an example of using a thesaurus to replace words in the sentence "The happy baby walked eagerly around the room" with synonyms.