He did not invite himself over. Sounds like your son invited him over. He checked with his mom who said it was OK. He called to tell your son and you answered the phone. All you had to say was that today was not a good day. End of story.
The kids in my life all do similar things. One child calls and says his mom says he can come over. The purpose of the call is to see if it's alright with me. I can either say, yes, that's OK or say no, not today. I don't see it as the child inviting himself over. I see it as the child learning how to negotiate socially. And I definitely do not see you as the bad guy.
If he were inviting himself over he would've rang your doorbell. Even then, no reason to get upset. Just say, not today. That does not make you the bad guy. It makes you the mom whose responsibility it is to make decisions about what is best for you.
Geez! When I was a kid and when my daughter was a kid playing together did not take such formal arrangements. Either my daughter could play or she couldn't. Either her friend could play or she couldn't. It's up to Mom to either say yes or no. No big deal however it happens, with a phone call or a knock on the door.
I suggest you're nit picking. You're making assumptions about the motive and how it fits in with your idea of what's good manners. Not everyone believes the same way you do. This is the way it is with children. You can find a way to manage this or you can make yourself miserable. You can insist that friends only come over when you personally invite them)or you can make adjustments based on what is happening at the time.Your choice.
I call friends and say I have some free time and would like to come visit. They do the same with me. I've not heard that this is impolite. The friend can say no or suggest we meet somewhere. It's all a matter of making arrangements to get together. Do you wait until you're invited to visit friends and family? This boy is a friend of your son. This is a part of their learning how to be friends.
If you don't want your son's friends to ask if they can come over to play then you need to teach your son how to stop this from happening. Is he old enough and his friends old enough to understand when he tells them to not call him to ask to play at his house?
I suggest that you can tell both children that you have to talk with the parent before any plans are made. This worked with my daughter and now my grandchildren. The child still calls and asks if he can come over to play and if I'm willing I ask to speak to the mom or dad. I suggest that it's reasonable to ask. It's reasonable for you to say no. The more I write the more I don't understand why a child calling to ask to come over is an issue for you. And even more, I don't understand why you feel like the bad buy when you made the logical decision to say no. You are in charge.
What do you want to happen and how can you broker that change? You cannot change other people so what can you do to feel better.
Later: Take a look at the big picture. Arranging to get together is often difficult for adults. Do you expect your young children to know how to navigate this without having time and experience in doing so? Perhaps it would be more helpful to think if there is a way to teach what you believe is good manners while accepting that others may not have the same expectations that you do. Feels like a complicated issue that will take time to work out.
In the meantime, know that you have an obligation to say no when what is asked will not work for you. And.......there is no reason for you to feel like the bad guy for saying no. You are the adult. You did the right and reasonable thing in this situation.