The smallest unit of sound that can distinguish meaning in a language is called a phoneme. A phoneme is an abstract sound category recognized by speakers, not necessarily one single physical sound produced identically every time.
English demonstrates the idea with minimal pairs such as “bat” and “pat.” Changing /b/ to /p/ changes the word’s meaning, so those sounds represent separate phonemes in English. By contrast, speakers may pronounce the same phoneme slightly differently depending on its position or surrounding sounds; such contextual variants are called allophones.
A phoneme is different from a grapheme, which is a written symbol or letter, and from a morpheme, the smallest meaningful unit such as “un-” or “-ed.” A syllable is a rhythmic sound unit that may contain several phonemes. Linguists usually write phonemes between slashes, as in /k/ for the initial sound of “cat.”