Young children learn family values from watching the ways parents and other family members treat them. If your family values include sharing, communicating, and respect, then those values will be observable in your child's environment.
It is not easy for little ones to share. When you see a situation like this one, use gentle reminders.
"Sharing is nice. You are sweet to your brother. He likes that."