Unfortunately a 2009 iMac is considered a real antique and it has been updated as far as it will go. The reason it cannot be updated further is it simply does not have the internal components to support current versions of Mac OS and no you cannot update the hardware internals.
If you want to run more current versions of Mac OS then it is time to replace the 2009. You have MANY options available to you. However I would caution you that buying a Mac from E-Bay is a TERRIBLE option as you have really no idea what you are buying and these often turn out to be disasters and a total waste of time and money.
If you want to buy a used Mac, please buy from a reputable source such as Macsales.com. However, you can also buy an Apple refurbished Mac too. To find these go to www.apple.com scroll to the bottom of the page and click the Refurbished section. Apple refurbished products are great, first they are identical to new, they come with the same 1 year warranty as a new machine, are eligible for AppleCare, and can save hundreds of $$ over a brand new machine. If you cannot find the option you want, check often as inventory changes very quickly.
Finally, when buying your next Mac please get one with a minimum of 16GB of RAM and the largest capacity SSD you can buy as these components are not upgradeable on current Macs.
If you have questions, please post them someone is more than willing to assist with helpful answers. Also, please remember that with any forum you may not get the answer you want to hear however in most cases with experienced posters such as hcsitas's the answers are the best options and are true and correct.