The accurate description of the legality of file sharing, wherein you upload music files that others can download, is:
It is not sharing, but stealing copyrighted work.
Uploading and sharing copyrighted music files without permission from the copyright owner is considered copyright infringement and is illegal, regardless of whether the files are shared with friends or involve well-known artists.