That entirely depends on your definition of “need.” Suppose you’re wondering if there is a strict legal requirement for it, are no. You can settle matters of custody among yourselves in a more informal manner, within certain limitations. For example, child custody defaults to being shared between parents after a divorce in most jurisdictions. So, you and your spouse can’t just decide that one of you has sole custody over the child. To switch from shared custody to sole custody, you two will have to talk to a custody and child support attorney, like the ones found on https://napadivorce.com.
You can, however, iron out the details of a shared custody agreement without a judge or a lawyer. Either through verbal negotiations or by putting together a basic written agreement. As long as both parties are happy with the arrangement and the children are being looked after properly, there is no need to get lawyers or judges involved.