It’s a basic psychological need to be able to trust that your brain can be right. A lot of psychological problems can result if you don’t trust your own brain to be able to solve problems and cope with new information.
Some people don’t learn the value of accepting mistakes/failure as part of learning. As a result, they will associate being wrong with weakening the trust they have in their brain. They don’t want to believe that their brain may not come up with answers for the problems and changes they face in life. So they will deny that their brain is incorrect.
It’s an ugly insecurity, but it’s totally understandable from an evolutionary perspective. We need to be able to trust our brains to navigate life’s challenges. People need to be taught that it’s okay to make mistakes, and that admitting when you are wrong is an opportunity for personal growth.