Chosen Solution

I have a imac 2011 but the hard drive is mess up can I buy any brand and it would work fine?

The brand should not matter as long as the form factor is the same. The 27 inch iMac 2011 uses a 3.5 inch drive. So you’ll want a 3.5 inch replacement drive. If you want to use an ssd, you’ll have to order an adapter/bracket to allow a 2.5 inch drive to fit as ssds only come in 2.5 inch form factor. I hope this helps. Feel free to ask more questions