While you can always manually defrag a disk ... there is an in-built option for Windows 11 and Windows 10 computers. You need to open the Optimize Drives wizard and click the Change settings ...
SSDs can't be defragmented, but the Windows tool for defragmenting and optimizing drives can still help optimize SSDs. However, no defragmentation is happening. Windows simply sends retrim ...
As you can see, the later versions of Windows don't require you to select disk defragmenter or even click "Defragment Disk" in order to get the process to run. Instead, the "Optimize Drives ...