The most common explanation is the fragrance.
Clothes strongly store the smell of the owner, thus giving the dog a sense of security and closeness. By lying on these garments, the dog feels close to the person he loves. For this reason, dogs often prefer unwashed clothing, as it has a stronger body odor.