Boxers, kickboxers, and MMA fighters train to be able to minimize the damage caused by a hit to the head. It's actually pretty hard to knock anyone out who has trained for any length of time in these arts.
One thing to realize is that you have a natural instinct to flinch whenever you see something coming towards your face. You might still get hit, but the fact that you saw it ahead of time means you began to get your hands up and your head out of the way. This diminishes the impact.
Another thing to realize is that tucking the chin can mitigate a lot of the impact force. Instead of it shocking your brain, it gets reinforced by your body and prevents the sudden recoil of the head. Boxers, kickboxers, and MMA people are taught this on day one.
And then there's conditioning. Getting hit in sparring by guys that aren't necessarily trying to knock you out but are still hitting hard will toughen you up and get you ready to take hits. Your body will adapt to it.
Conditioning also means strength and stamina. Having a strong body that doesn't get fatigued during a fight is vital. If you gas half-way into the first round, your odds of getting knocked out go up a lot. It means your defense becomes weak. You stop being able to move to avoid hits. You'll go down quickly.
There's age and previous knock-out history as well. The more you've been KO'd, the more likely you'll be KO'd. I think it's just that the body wears as you get older and have been subjected to more damage.
Having a history of being KO’d before also means you’re less likely to continue fighting. The people left in the game are, therefore, people who either have little experience or who have lots of experience. Those who stay as fighters a long time are people who don’t get KO’d easily. So it’s kind of a selection bias. These aren’t typical people. These are exceptional people.
Lastly, there's genetics. That probably counts for a lot. How your body is put together, whether or not you're able to grow muscle in all the right places, your brain's response to low/high blood pressure and adrenaline, etc. Genetics plays a role. How big? I don't think anyone knows.
Hope that helps!