The DMG file is essentially a mountable disc image that shows up on your desktop when opened. In most cases, the DMG file is used to give the Mac devices the ability to install different types of files and software originating from the internet.
The DMG file extension was created by Apple and is primarily used on Macintosh computers and devices.