If you haven't updated your Mac's operating system in a number of years, then you need to check to see if you are running at least OS X 10.6.8 Snow Leopard, which was released way back in 2009.
Or watch this video about how to upgrade the RAM on a MacBook Pro. You may wish to read our article on upgrading your Mac's memory.