You say that your iPhone has 2 TB of storage.
There has never been an iPhone with 2 TB of storage. Even a fully loaded iPhone 15 Pro Max would "only" have 1 TB of storage. What you are probably referring to is iCloud storage space – space that you are renting on Apple's servers for making backups, and for synchronizing data between your iPhone and other devices.
What your phone is probably telling you is that you are out of local device storage. Your phone needs local device storage to do just about everything, and you cannot purchase more device storage for an iPhone. Whatever flash memory chip(s) it had when it rolled off the line at the factory are the ones it will have until the day that it dies.
If you are using iCloud Photos, you can turn on the "Optimize iPhone Storage" feature to let your phone substitute low-quality local copies of photos and videos for full-quality copies when it sees that you are running out of space. The idea is that iCloud always has the full-size versions and the phone can re-download them, on demand, later.
Aside from that, managing local device storage is something that you pretty much have to do.