These types can't usually think clearly under pressure. Besides, answering coding questions is very, very different from inventing those algorithms. It's a completely different way of thinking. That's why.
But does that mean they're bad programmers? I don't think so at all.
As a young person, we grew up with the internet so we're conditioned to just know the "pointer" to the information and then have to google/search for it.
Now I've learned all the algorithms and data structures at uni too and passed the exams but what remains are the names of them and roughly when they are needed. It may be unfortunate but that's what it is like to study nowadays. It's all about cramming everything into your head and passing. Distractions absolutely everywhere and anxiety that we won't live up to and have the lives our parents had.
Now i for one dislike leet code and coding challenge interviews. I think it's silly, plain and simple. What i would look for instead if i was an employer would be curiosity. Nothing is more important than insatiable curiosity. A curious employee will learn everything about your whole stack in the first week... just out of curiosity. And if they do hit a leet code like problem during day to day work you best believe their curiosity won't let them rest until they've solved it, be if with prior knowledge and experience or without.
I could spend a day doing the hackaton project or I could spend it teaching basic computing to someone who thinks himself an expert and is unwilling to learn. But I can't stop time, so can't do both.
It's almost certain some of then (maybe most of them) would have fared just fine if they were left with the problem alone, not in a high pressure setting like a job interview.
I agree pressure can play a part, but thinking clearly under pressure can be a very important skill to assess in a candidate depending on your company. For a high growth startup, there is often a lot of pressure to deliver effective code quickly. I also think retention of knowledge plays a large part.