USB drive disconnects by itself and doesn’t reconnect until I reboot (2015 Macbook Air)

I have a USB drive which randomly disconnects. I would think that there is some hardware fault with the drive itself, but if I unplug it and plug it back, it doesn’t reconnect unless I just rebooted the computer, which gives me hope for a software issue.

I don’t know whether it’s relevant, but currently I’m trying to download something heavy directly onto the USB drive, and that’s when the disconnects happen. I’m not sure whether they would happen either way though.

Ideas on how to solve this?