Many things that you have to deal with during divorce are going to be challenging. One thing that can complicate matters even more is when you have children who are looking to you to find out how they should react to the situation. As a parent, you have a duty to protect your children. During this transition time, you might have to do a bit more to help them through their emotions.
One thing that you need to do from the start of the divorce is to keep any negative conversations away from the children. They don't need to see any fighting between their parents, so make sure that you don't hash those out around them. There should be private times when you can discuss contentious matters with your ex. Along this same line, be sure not to use the kids as messengers back and forth.
Another way that you can help to protect your children is to discuss the divorce with them. This doesn't mean all the nitty-gritty matters. Instead, talk to them about things that impact them. You might need to go over the schedule or discuss the fact that you want them to have a relationship with their other parent.
All of the child custody decisions you make should be clearly covered in the parenting plan. This ensures that there is consistency with their care. If you and your ex can work together as a team, respectfully, you can help your children to thrive despite having to live in between two homes. When parents co-operate with each other, divorce is infinitely less distressing for the kids.