Fix copy=True behavior for torch.asarray when device is not None/cpu (#108511)
Fixes #108408
See issue for details
Pull Request resolved: https://github.com/pytorch/pytorch/pull/108511
Approved by: https://github.com/ysiraichi, https://github.com/rgommers, https://github.com/ezyang