If I program something to always reply “2” when you ask it “how many [thing] in [thing]?” It’s not really good at counting. Could it be good? Sure. But that’s not what it was designed to do.
Similarly, LLMs were not designed to count things. So it’s unsurprising when they get such an answer wrong.