Buzzing noise after reassembling iMac 20" 2009
The most likely cause would be the fan causing the noise. See this post from bMike 'Is it possible to install an SSD ...imac'  where he points out that 
"..the immediate downsides - You will need special tools and be handling some delicate parts. Also, there is concern that the temperature sensing since the 2009 model iMac causes the fans to run faster with non-apple drives."  I have also had the problem with the fan going into overdrive and creating a horrible buzzing, so I am aware they are susceptible to this happening.  It is also possible that some foreign material got lodged around the fan, so that is worth checking too, and definitely keep an eye on the temperature.