You are asking how to force someone to think differently.
Perhaps a more helpful answer would be to answer, not what you asked, but to understand where you are and try to offer some advice that you did NOT ask for.
You have a boyfriend, a presumably emotional attachment to someone you're not married to. This person acts without considering you or what you think, and does so in ways that impact you emotionally. Perhaps even ways that severely disrupt your day or emotional well being. Is this correct?
First, perhaps you need to understand that men do NOT tune in to women's emotional hints. They are not particularly empathetic by nature. There's no problem until it's brought up, specifically, addressed by solving it and then moving on. This is extremely emotionally unsatisfying to women, who want men to pay attention to their emotional state, and react accordingly. Except they don't see it that way. The most "caring" man in the world may be utterly blind to your emotional state, even though he cares for you enough to jump in front of a moving train to shove you out of the way, sacrificing his life to save yours. That ( dedication, caring, valuing you ) does NOT enable empathy, so that he intuitively knows what you want or recognize when he does things you can't or don't want.
You need to have a heart to heart discussion with him, and speak language HE understands. Like, "why did you do x, when you knew it hurt my feelings?" And then listen. If he berates you for being stupid about your feelings, then send him packing. If he is taken back and shocked, then you need to learn to communicate TO HIM in language he understands, on how to be in a relationship with you.
See, when you say: "You always go out with your friends and leave me alone" you're probably meaning that when he goes out with his friends, he didn't talk to you about it and make sure you were ok with each instance, making sure he didn't make plans that overrode plans you had for you and him and he didn't even ask you.
However, to him, the statement is angering and annoying, because it's untrue. He DOES go out with you and do things with you, so the statement is untrue AND you also have no right to tell him he can never go anywhere or do anything with anyone else. THAT IS HOW HE WILL SEE IT. He takes your complaint literally, you're just describing your emotional state.
Both of you must learn to speak to each other, to be understood.