How to connect a 3.5mm microphone (not amplified) to an iMac for recording?
What you need is a audio mixer (I personally use and like the Behringer line)

 

The inputs/outputs built in to computers (both Macs and PCs) are basically rubbish - they are looking to give you functionality to mark a check box for marketing purposes, not give you the ability to make good to professional quality recordings..

This mixer will give you a USB interface to your Mac while allowing you to bring two sources in while having granular control over input sound levels.   

Granted, it's not a "free" solution, but at $30 USD, it's a very economical solution that gives you better quality and more flexibility than what you have at present.