Get him alone, get him receptive (be in communication with him and be willing to hear what he has to say), don't try this when he's defensive already or ignoring you or pretending you're not there or not saying anything—and then have a talk with him.
Here's roughly how I would do it:
"You're a big brother now. Did you know that?"
He might ignore the first time you say it. Don't get annoyed, don't raise your voice. Just acknowledge whatever he says, even if completely disrelated ("I'm wearing socks!") and then say the above again.
"Hey, I got that; you're wearing socks. Okay. Hey—you're a big brother now. Did you know that?"
If you do this more than a couple times, don't get impatient. Don't get annoyed. Instead, you might try (very calmly, without even a hint of annoyance), "Hey, I said something. Did you hear that I said something?" If it doesn't seem dangerous to answer you, because you're just friendly and in communication, he'll eventually say, "Yes, I heard you." Then you say, "Okay, good. Did you know you're a big brother now?"
He'll probably say, "Yes, I did." Or maybe he'll be being contrary and he'll say, "No."
If he says "yes" you acknowledge him—"Okay, good!" and go on to the next step.
If he says "no," again, don't get annoyed—just tell him: "Okay, I got that. Well I'm letting you know now: You're a big brother. Did you get that?"
Again, if he ignores you (or asserts through his actions that "you didn't say anything," which is different from ignoring), don't get annoyed. (I can't stress that enough.) Be, yourself, safe for him to talk to. And carry on to get the communication through, without annoyance or other negative emotions.
I would even go so far, if he tried to run away from the conversation, to grab him in my arms (gently, friendly) and just gently repeat, "Hey, so you're a big brother now. Did you get that?" "Let me go!" "Did you get what I said?" The key is gently. It's done with understanding; understanding will melt his "ignoring" of you.
Once you've gotten it across that he's a big brother now, you can tell him, by the same methods, that his little sister will learn things from him. (Once you've gotten the first statement across, in my experience, you won't have much trouble with receptiveness for the rest of it.)
"Your little sister will learn things from you. Did you know that?"
Or: "No." "Okay. Well, do you remember last week, when she saw you picking up a fork and she picked up her fork?" "Yes." "Okay. She does learn things from you."
"And, she can learn good things from you, or bad things." (Just get a nod, or a receptive look that he is continuing to listen.)
"You're a very good boy, almost all of the time." (Even if you don't think this is true, it is. You need to have your mental attitude in place expecting your son to be an amazingly good boy. Then you can communicate this with sincerity and make it even more true.)
"We would like you to help your sister to be a good girl, also."
"What do you think about that? Does that sound like a good idea?" He'll say, "Yes." Or else find out what he does think about it.
Then, thank him for listening. And let him go play. "Okay, thank you! I'm glad. Now, you want to go to the kitchen and play with your mommy?" (Or whatever he was seeking to do next before you started the conversation.) "Yes." "Okay, you go ahead. I love you!"
I doubt you'll have much trouble with the subject again.
Getting really into communication with him is the key. It's pure magic.