What makes a food protein an allergen?

What makes a food protein an allergen?