Cannot reinstall OS X on a MacBook Pro (13-inch, Mid 2009)
You'll want to load the computer into what's known as Network Recovery (or Internet Recovery) by holding down the following buttons while turning the computer on: Command, Option, and R. You will need to know the password for your Wifi network. 

When you're loaded into the right menu, you'll look for Disk Utility. Once Disk Utility, look for the name of the disc on the left hand side. You should see the name of the hard drive (i.e. Apple HDD 512GB etc).

Select the Partition button if you're using the native 10.11 Disk Utility or the Partition tab in the middle if you're using the lower systems. 

If you're using the newer system, it should by default auto-adjust the partition to the right size and format. If you're using the old one, follow these steps: 


Go to Partition type and change the drop down from "Current" to "1 Partition." 
Change the format to "Mac OS X Extended Journaled."
Give the disk a name in the field on the right. Macintosh HD is the default name for Macs out of the box. 
Click on "Options" and choose GUID Partition Table. Click Ok. 
Click Apply, then Partition. 


Once this partition is created, you sh[ould be able to install OS X on your new hard drive.]

This will allow the disk to be formatted into the proper format and should allow it to install on the new HDD.