The RAM is not user upgradable, because the iMac must be completely dissembled.
If you go to > Install memory in an iMac - Apple Support
and look at your model, you will notice that there is a #3 footnote.
3. Memory is not removable by users on iMac (21.5-inch, Late 2012), iMac (21.5-inch, Late 2013), iMac (21.5-inch, Mid 2014), iMac (21.5-inch, 2017), iMac (Retina 4K, 21.5-inch, 2017), and iMac (Retina 4K, 21.5-inch, 2019). If the memory in one of these computers needs repair service, contact an Apple Retail Store or Apple Authorized Service Provider. If you’d like to upgrade the memory in one of these models, an Apple Authorized Service Provider can help. Before you schedule an appointment, confirm that the specific Apple Authorized Service Provider offers memory upgrade services.