Dns server setup in site to site connection

I have connected two private networks of two different cloud. On the vm where the twingate client is running is able to resolve the domains, but I have also done the routing so that the whole network can access the other private network. How can I make that twingate vm a dns server as well?