Hello SH_Quietly_be_better,
Welcome to Microsoft Community.
I am a Microsoft user just like you, I hope you are well.
Sorry for the inconvenience. However, if you have your OneDrive synced to a device and you delete a file in OneDrive, it will delete this file across all synced device. Same is applicable to adding a file to OneDrive, this file will be available on all devices.
What you ought to have done was move this file out of your OneDrive folder.
I understand your frustration but OneDrive functioned as expected. If you do not wish to sync your device with OneDrive, you can unlink OneDrive from your PC using guidance from Microsoft support article: https://support.microsoft.com/office/f32a17ce-3336-40fe-9c38-6efb09f944b0
Please let me know if you need more assistance.
Give back to the Community, Help the next person who has this issue by indicating if this reply solved your problem. Click Yes or No below.
Warm Regards