Using the Mass File Download App, you can download the CSV Mapping file, and from this Mapping File, you can collect the File/Attachment IDs. Then, using Workbench/Dataloader/Dataloader.io, you can delete the files and attachments.
Before we start, let's talk about the most important step: If you need a backup of your files or attachments before deleting them, please make sure that you download these files/attachments first before proceeding with the below deletion process.
Follow the below steps to Delete the file and Attachments:
- Go to Mass File Download Tab > Select the Related files & Attachments sub-tab.
- Select Object and Search Mode as per your requirement then click on Search Button.

- Search Results will display below here click on the Download button and download files & Attachments if you wanna store them for future reference. Or Select the files and Attachments which you want to delete and click on the Download CSV Mapping File button.

- Open the Downloaded CSV mapping file and Remove all other columns except ID and save the file in the .csv format.

> Log In to Workbench (You can use Dataloader or http://dataloader.io )
- Click on Data and Select the Delete option
- Choose From File radio button → Click on Choose File and the upload the CSV mapping file which you edited in the above step.
- Now click on the Next button.

- Map Id fields

- Now click on Confirm Delete button.

- Now you can see all related files are successfully Deleted.

PS: View Mass File Download, Salesforce file download app on Salesforce AppExchange: https://appexchange.salesforce.com/appxListingDetail?listingId=a0N3A00000EcsAOUAZ