Let’s be 100% clear. When you cross the border into the USA, you have to go through US customs, not Canadian customs.
If illegals are making it into the USA from Canada, they’re getting there by going through US customs. They drive over and go through US customs or they fly over and go through US customs. So your question should really be “Why can’t US Customs get control of their border?”
Now, you might squawk “what about those people who are walking across the border illegally?” Go ahead and try to walk across. Right now it’s -25C (-11F). Go for it. Have fun. Don’t believe me? Ask anyone from Minnesota or North Dakota (or just watch Fargo… again and again until you understand how cold it is).
What about spring? Yeah, good luck with that too. Most of the Canada-US border is wilderness. Not a few miles (kilometers), many. It’s not a walk in the park. Good luck with that as well.
In other words, if there are going to be a few hundred people who are stupid enough to try any of that, they’re probably going to die. But if they do make it, so what? It’s a tiny number of people. Nothing significant at all.