Back up your disk, apps, settings, documents first for safekeeping. Erasing the boot disk would require starting up from a different disk. Erasing then would wipe the whole drive, including the OS. You can then re-install the OS, from an earlier downloaded installer, or else from the internet.
How to download and install macOS - Apple Support
Download OS X Yosemite 10.10.5 (.dmg) - Apple
Else delete your documents manually, but that is possibly less thorough.
iMacs from 2013 can run macOS up to 10.15 Catalina. That will likely use a bit more disk space, though. Depending on your needs with this machine, that may or may not be beneficial.
Bringing a bigger drive into this iMac, would require dismantling the screen. That may warrant professional assistance.
What drive (or drives) does it have currently? What storage total?
2/4/8/16 TB internal fast SSD drives are possible, but only you can decide if that is worth the investment.
You can also work with external drives, even for boot disk (OS), then you wouldn’t need to open it up.
What is the exact model iMac? Identify your iMac model - Apple Support
21.5-inch, 27-inch?
i3-3225, i5-4570x, i5-4670, i7-4770S, i7-4771?
2.7, 2.9, 3.1, 3.2, 3.3, 3.4, 3.5 GHz?