Welcome to the Apple Support Communities.
If you did not follow these steps to remove the Windows Boot Camp partition, Remove Windows from your Mac using Boot Camp - Apple Support, then you must erase your entire startup disk to reclaim the storage space.
However, since this will erase all data, you need a backup. If you do not already have a Time Machine backup drive, here’s an excellent one sold by Apple: G-Technology 4TB G-DRIVE mobile USB-C Portable Hard Drive - Apple. You can then follow the steps in this Apple Support article to setup your Time Machine backup: Back up your Mac with Time Machine - Apple Support. After a successful backup, you can erase your Mac.
Shut down your Mac, then startup into Internet Recovery Mode (Option-Command-R) by immediately pressing and holding those keys at startup. Then, Use Disk Utility to erase an Intel-based Mac - Apple Support. When in Disk Utility to erase your startup disk, select "View" > "Show All Devices" to erase the main SSD (its name will end in "Media"). After erasing your startup disk, reinstall macOS: How to reinstall macOS - Apple Support.
After erasing your Mac and reinstalling macOS, you will be presented with a Setup Assistant. Set up your Mac again and restore from your Time Machine backup: Restore your Mac from a backup - Apple Support.
Jack