Connecting containers to a private network allows them to communicate with each other using their container names as hostnames.