A literary foil is a character whose purpose is to accentuate or draw attention to the qualities of another character, most often the protagonist.