A child is very hard to manage because what they see is what they do. However, giving them proper freedom and accompanying them with guidance will lead them to the right path.
Be sure that you show your child a good example. If you want them to do something, it is you who must do it first.
Children often make mistakes and they do not know that it is wrong. Do not scold them. Instead, tell them in a calm manner what is the correct thing to do.
When the child is in the teenager stage, this is the time they want to socialize with others. Let them do it, but still guide them. Know who the people around your child are. Deepening your relationship with your child is also important in this stage, so that whatever they do, they will tell it to you.