If you are trying to push some application in the network where you have macOS, you might need .pkg file rather than .dmg.
In this blog, I have taken the reference for Skype. You can follow the same command line for other application.
First, start by mounting the application’s .dmg file. Don’t drag the file to the application folder.
Note the name of the mounted volume and the app itself.
sudo pkgbuild --install-location /Applications --component /Volumes/Skype/Skype.app ./Desktop/Skype/Skype.pkg
It is done and you will get your pkg file in Desktop. Quite straight and easy, isn’t it?