Backing up an iPhone via a PC or Mac works without any issues. However, if you want to connect it directly to the iPhone using a cable or adapter, the phone's port does not provide enough electrical current to run a 5TB mechanical hard drive: you will necessarily need to use a mains-powered USB hub (and have the drive formatted in exFAT or APFS) for the iPhone to be able to read it.