If only the 256MB setup volume is visible rather than the whole 2TB drive, select View > Show All Devices.
Select the 2TB device and press "Erase".
Choose a name, select "Mac OS Extended (Journaled, Encrypted)" (Time Machine doesn’t support APFS as it needs hard links to directories) and "GUID Partition Map" (Time Machine prefers GUID Partition Map, MBR is for Windows, Apple Partition Map is for old PowerPC Macs), then press "Erase".
When Time Machine pops up, check "Encrypt backups" and accept the dialog.