Human beings are social animals. Part of raising a child is helping them learn a set of social and emotional tools that will help them have positive interactions with others as they get older.
So, yes, to some extent it is indoctrination. You’re choosing SOME thoughts and behaviors to encourage and SOME to discourage. If you’re thoughtful about it, you’ll try to encourage things that will probably help them later in life (share with your friends) and discourage things that will probably hurt them (violence is a good way to solve problems).
But as kids get older, they start to think for themselves. They take the basic ethical and moral principles you taught them by indoctrination when they were little and play around with them: Do they hang together as a coherent system? Do they lead to desirable outcomes in their day to day lives?
We teach our kids right from wrong when they’re tiny to give them a good foundation as moral beings. But by the time they reach adolescence they should be capable of taking those moral lessons and analyzing them autonomously. The goal is not to provide a fixed set of immutable rules that they will follow for the rest of their lives, but to give them a general framework for thinking about moral problems that they can use to generate their own rules as the situation demands.