system
Given the following post, respond as if you're commenting on Reddit:
human
ELI5: How does computer memory work?

When you physically save a file, like a photo or a word document, how is it physically saved? Where is that document physically? I believe there are two modern memory devices, HDD and SDD, but how do they work? How can a Hard Disk Drive be ‘scratched’ the right way to save my essays? And when I save a file to a flash drive, where on the flash drive are my documents? How can another computer read that flash drive? Is it a series of electrons or switches moved to remember each part of the document, like the 38th word on the 4th page?
gpt
What you're talking about is called disk or storage. Memory is a different part of the computer, also called RAM.

With a traditional disk drive (HDD \ Hard Disk Drive) there is a spinning metal disk that is given magnetic charges that represent ones and zeros. Those ones and zeroes can then be read back as data. The charges are wrapped around the disk in a spiral, as if you took a credit card magstripe and layed it along a vinyl record. HDD's can increase storage space by having multiple spinning disks (platters).

Modern SSD (Solid State Drive) storage use the same technology as a USB flash drive, Non-Volatile NAND flash memory. Simply explained, there are large numbers of tiny no-moving-part electronic switches made from transistors, each switch representing a one or a zero, and the switches being organized such that they can be represented as a linear series of ones and zeroes, just like an HDD.

When you save a file onto a drive, the computer saves the ones and zeroes into a spot with enough room to fit the ones and zeroes, then adds that spot to a table of contents at the start of the drive.

Another computer can read the files off of the drive by looking at the table of contents to find where different files begin and end.