hdiutil detach /Volumes/Install\ OS\ X\ El\ Capitan

Mount the newly created image to a temporary volume directory.

Finding a high-quality, safe, and reliable download for Mac OS X 10.11 El Capitan can be tricky, as Apple has officially moved on to much newer operating systems. Whether you need it for a legacy Mac, a virtual machine, or to create a bootable installer, this guide covers the most secure ways to get the official installer and convert it to a high-quality ISO file. Official and Reliable Sources

Before installing, verify that your hardware meets the minimum technical specifications: Apple Support OS X El Capitan - Technical Specifications - Apple Support