This article will show you the steps for how to create ISO virtual disk file from the folder in macOS.
Step 1: Open Disk Utility.
Step 2: Click on File > Image from Folder > Browse to and select the folder > Set the Image Format to DVD/CD master then save it on Desktop.
Step 3: A CDR disk image created on Desktop, open a Terminal and execute the following command to convert CDR disk image to ISO image:
hdiutil makehybrid -iso -joliet -o -FILENAME.iso FILENAME.cdr