iCloud Drive Splitting Folders
It’s difficult to know exactly what is happening, but it seems iCloud Drive is generating extraneous folders during conflict resolution.
[…]
For many apps, this is no big deal, and may never arise. But if your app stores data at specific paths in iCloud Drive, it could very easily become a problem.
[…]
If you are removing and re-adding folders in your app at a specific path in iCloud Drive, don’t be surprised if one day you discover the data is gone, and moved into a second version of the folder at a different path.
I consider this pretty undesirable behavior. No other sync solution I know does this. Dropbox doesn’t — although Dropbox does do something similar to this with files rather than directories — and the original iCloud file sync also didn’t do it.