Use early 2009 20" iMac as external display for 2015 rMBP
This cannot be done with your particular iMac (2009 20")

Per the Target Display Mode System Requirements Page it specifically says:


  A supported iMac with OS X v10.6.1 or later.


The supported iMacs are:


  
  iMac (27-inch Late 2009)
  iMac (27-inch Mid 2010)
  iMac (Mid 2011)
  iMac (Mid 2012-Mid 2014)
  


However, there is an App that allows you to turn a spare Mac into an extended monitor.  It's called Air Display.  This is not my ideal solution as video intensive applications don't perform well with software solutions.

If you need a secondary monitor, you may have to get a dedicated monitor to meet your needs