So this is my first posting on the philosophers stack exchange, just keep that in mind if you have any critiques then let me know instead of just downvoting, this isn't reddit.
The way I've always seen it, is that logic, and mathematics, is a discipline. It's a thing you learn and get better at.
As others have mentioned, the brain is a complex machine. There is a lot that goes on under the surface, which would include a level of reasoning. This reasoning would be applied to your everyday situations. In fact infancy hits a stage where they utilize this reasoning on the most simplest of things, like turning things, and by things I mean EVERYTHING, upside down to see what happens. Who is to say that their experiments as a child were flawed, or happened to go horribly wrong for them, which is probably more along the side of phobias and the like.
There is a good handful, or wheel barrow full, of things that can mess with that reasoning. Another person mentioned tribes and how individual rationalism wasn't a thing that was accepted with open arms for the most part (seriously, count the great minds that were shunned, more on the side of not invited to dinner parties and less on the side of cast out of the village, by most of society in the past). Emotional reasoning is another thing that tends to get in the way of logic, which I imagine is at least one reason Socrates was so down on emotions and the senses.
So we have this basic human reasoning, which can be baffling at times. Formal logic is our counterpart to that. Yes, at some point in time somebody or some people created formal logic, or at least discovered it was a thing they could do. Which I have always thought of it as math but with statements. So you can then take your reasoning and thoughts and what have you, and put them into this mathematical formula and do all this weird stuff to prove them right or wrong. Most people don't do this. If they do this, and are still illogical, then that means they are using false statements from the get go, and sometimes there is no getting through to those types.
Edit: To be fair, most of those that use the false statements think they aren't false, its not because they are stupid, just misinformed for the majority of their life. It can also happen to anyone. For example, I believe a good number of you know about the Berenstein Bears, however most people did not know that the correct spelling is Berenstain Bears. Here is a fun article that claims we jumped into a parallel dimension. I mean, the example doesn't have the same scope as someone inherently believing black people are inferior, but I hope it gets the point across with it being fairly easy to learn something like that.
I'm sorry if I referenced too many other answers, I at least want to acknowledge that it was stated before to give credit to those who answered before me, as they went into greater detail on most those subjects than I did, and a good number of them dropped some pretty awesome links, or at least a title of a book.