There are two types of meaning associated with the words 'vowel' and 'consonant'. First, the phonological definition says that consonants are simply those segments that occur at the edges of syllables, unlike vowels which occur at the centre of syllables. Therefore in 'cat', 'book', 'mean' the sounds represented by <c, t, b, k, m, n> are consonants and the sound represented by <a, oo, ea> are all vowels.
To know what kind of sounds generally occur in those different positions in syllables we need a phonetic definition. It says that vowels are median so the air escapes over the middle of the tongue, oral so the air escapes through the mouth and never through the nose which means that the soft palate is raised but I shall talk more about the place and manner of articulation on the other occasion. The phonetic definition also says tat vowels are frictionless (thus excluding fricatives e.g. /s/) and continuant (thus excluding plosives e.g. /p/). Basically all sounds that are excluded from the phonetic definition are consonants.
However, nothing is ever easy in English because /j, w, r/ are consonants phonologically since they certainly occur at the edges of syllables but are still vowels phonetically because they are all median, oral, frictionless and continuant. For that reason we call them semi-vowels.
Another difficulty arises in words like 'little' when the final consonant /l/ (we are not taking into consideration the spelling but the prononounciation) is the syllable on it's own thus must be the centre of such syllable too even though phonetically /l/ is not a vowel. This situation ocurs for laterals (/l/) and nasals (e.g. /n/) therefore laterals and nasals are called syllabic consonants.