OK.... Two issues, memory and hard drive...
Memory...
First, look under "About This Mac", then "Memory" and determine if you have four 2 gig chips, or two 4 gig chips...
Adding more memory is possible, on the 2010 with a Core I3 processor, 16 gig is the max. four 4 gig chips...
On the 2011 Core I5 and Core I7, 32 gigs is the max. Four 8 gig chips...
I get my memory from Data Memory Systems dot Com, Other World Computing is another good source...
I recommend at least 16 gigs...
Hard drive...
The 2010 and 2011 hard drives had thermal sensors built into the drives. Other World Computing has external replacement sensors, allowing you to use any drive...
https://eshop.macsales.com/shop/imacdiy/
(Note that the 2010 iMacs have a SATA III interface, 6 gigabytes a second, but a SATA II drive, 3 gigabytes a second...)
These old iMacs are not hard to take apart, look on ifixit dot com for directions.
Look on New Egg for hard drives, I recommend Western Digital Black platter drives, and Samsung EVO SSD's
https://www.newegg.com/black-wd4005fzbx-4tb/p/234-000G-000W6?Description=western%20digital%20black&cm_re=western_digital%20black-_-234-000G-000W6-_-Product
https://www.newegg.com/p/pl?d=samsung+860+evo
If you run a 2.5 SSD, you will need a 2.5 to 3.5 adapter...
https://eshop.macsales.com/item/NewerTech/ADPTADRV/?GCh19-Ax_EAQYAiABEgJxhfD_BwE&gclsrc=aw.ds
I am running 20 gigabytes with a 4 gig platter drive, plenty fast...