You must lead by example. And show that it works. And, very importantly, not confuse matters by associating the desired or undesired behavior with interpersonal physical, emotional, or economic return.
If you associate the behavior with physical punishment, the child will associate the behavior with punishment when you are present OR, worse, the child may compare such behavior as equivalent to other types of behavior from their peers and seek to punish them.
If you associate the behavior with emotional punishment, then the child will hone more subtle & sophisticated ways of circumventing and manipulating your emotions in relation to the behavior. They will then apply those same emotional tricks to other people in life.
If you associate the behavior with compensation, then they will come up with a pricing/blackmailing system in which they behave in certain ways depending on degrees of payment.
So, WATCH OUT! How you treat them can turn on you. I heard a Native American once say that, in his culture, parents understood that, one day, the small child will be big and the big parent will be small.
Children learn through observation. And, by personal association/identification, they must personalize the values you wish to cultivate inside of them. This does not preclude you from expressing yourself and also demonstrating how to deal with other adults who see the world differently and play by different rules.
But, remember, how they observe you teaches them what are the most effective ways of living through life.