CODEC is an acronym for coder/decoder, or more completely, encoder/decoder.
A codec is software that ‘knows’ how to encode and decode a specific audio or video format.
For example, one encoder might be used to create or interpret certain types of “.avi” encoded videos, while another might be required to handle “.m4p”.
In practice, most audio and video applications come with a set of codecs that allow them to be able to handle a certain pre-defined set of formats, typically those most commonly used. Only when a file comes along that is not in one of those formats is it necessary to consider locating a codec that understands it, or finding a different application that comes with a codec that supports it.