Add create_net_xml function to define a new or existed network.