Lily didn't want him to hang out with the Slytherins, but who would he hang out with?? He lived with Rosier, Avery. He would get bullied by the Slytherins if he didn't hang out with them.
Lily: Severus, your friends are bad and insult people. You should hang out with other people, like me, I hang out with super cool people.
Severus: Your friends go along with the guys who’ve been bullying me since first year, Lily.
Lily: Well, yeah, but they don’t use dark magic, Sev. It’s not the same, you know???
Severus: Right, but don’t you think it’s a bit illogical for me to stop hanging out with the only people besides you who don’t treat me like crap and try to fit in with your friends, who are the first to laugh when those four try to ruin my life?
Lily: Look, I don’t want to keep talking about this. It’s costing me my popularity that you hang out with those evil people. You should be grateful that I defend you in front of my friends.
Severus: But your friends...
Lily: I can’t take it anymore! Just leave me alone!