iCloud kind of does this and is the suggested way to store app data files.
It’s not immune to file conflicts across your devices though.