How to add DNS changer in my app

Basically I am talking about DNS I know many VPN app doesn’t work in background Thier provide hostname and password to android settings in here :point_down::point_down:

So all Vpn provide the information about host and pass to android Vpn setting

So how can I provide the information about host and pass

I want to add a feature which know as DNS changer

Vpn and DNS changer doesn’t run in background Thier provide information of server to android Vpn setting to connect you with server

So how can I do any idea about that