From time to time I noticed strange filenames on the Synology Diskstation. Names like BGELMF~0. They always had a tilde. Those strange names are called mangled names. Samba has a feature to provide them to bad clients. Unfortunately this can also lead to "renaming" those files.
It is better to prevent this behavior altogether. To do this you need to connect over SSH to your diskstation and then you need to login as root.
Issue the following commands:
Now insert the following line in the section global: