So 'basically a friend of yours' is wondering about the legal and ethical issues over him having possession of an
imac which someone else purchased... no matter how it all came about there is someone out there who paid for an imac and your friend is in possession of same imac. Anyone having to work out the moral or legal issues of that situation needs to step back and consider their own sense of moral responsibility.
Whoever paid for that imac, has no proof (no receipt) of purchase - they could have saved a long time for the item, it could have been a gift for someone etc so do you honestly think keeping the item will be hurting no-one?