Can I build a closed network with multiple VMs and free5gc?

I am not good at English and use a translation app.
I apologize if I have expressed myself in a rude manner.

I used Oracle VM VirtualBox to build three machines: a machine with free5gc installed (IP:192.168.56.107), a machine running the Apache server (IP:192.168.56.109), and a machine sending requests to the Apache server ( IP:192.168.56.106), and the machine that sends requests to the Apache server (IP:192.168.56.106).

Join two machines to the free5gc network: the machine that sends requests to the Apache server (IP: 192.168.56.106) and the machine that runs the Apache server (IP: 192.168.56.109), and communicate using the free5gc protocol. How to do this?

free5GC is a 5G core network.
It speaks 5G protocols specified by 3GPP.
There’s no such thing as “free5gc protocol”.

I don’t see how free5GC is related to Apache server.

Thank you for your reply
I apologize for my lack of understanding.

My goal is to have free5gc communicate with multiple VMs.

Please draw a topology diagram of what you want to achieve, and then I may be able to help you.

According to my understanding you can do multiple vm connections. For example I create a setup UPF in one VM, AMF and other microservices is another VM, UE and GNB is another vm and they connect via their IP addresses and work succesfully. Just remember while you running microservices be sure at IP addresses in config files is true and accessible via each other.