This may be done either by the operating system or the application software. Virtual memory is much slower than RAM since the contents of RAM must be swapped to disk to free RAM for working on other parts of the image. An adequate amount of RAM reduces the number of times the computer needs to access the hard drive for image data.
Images usually require temporary storage during processing.
For instance, when compositing several images, you may need quick access to each image component. A dedicated hard drive provides quick access as well as very high transfer rates.