What is the purpose of the filing of an answer

What is the purpose of the filing of an answer by the defendant?