Its pretty simple actually, the owner of the copy 'right' expressly authorizes the copy being given to you. That is in accordance with the law. So any number of examples, you buy a book at the book store, you buy a DVD, you watch a movie at the theater, all of these actions result in a 'copy' of the work coming into your possession that is sanctioned by the owner of the right.
Any illegal copy is one in which the owner hasn't sanctioned transferring a copy to you.
Copyright law carves out specific exemptions for lending libraries and the First Sale doctrine, part of the unified commercial code (UCC) gives you the right to transfer your copy to a third party as long as no new copies are created (so you no longer have a copy).
Note I am not a lawyer, and this is not legal advice.
Any illegal copy is one in which the owner hasn't sanctioned transferring a copy to you.
Copyright law carves out specific exemptions for lending libraries and the First Sale doctrine, part of the unified commercial code (UCC) gives you the right to transfer your copy to a third party as long as no new copies are created (so you no longer have a copy).
Note I am not a lawyer, and this is not legal advice.