Ok I tried my best and thats the result: It works on my device and you get a thing looking like this out of the DocumentTree:
content://com.android.externalstorage.documents/tree/9C33-6BBD%3Afolder1%2Ffolder2
In Java there is a function for this (
DocumentFile pickedDir = DocumentFile.fromTreeUri(this, treeUri);) but as I can only handle this string i fixed the information in it and added storage paths etc.
(This is only tested on Samsung Galaxy S4 and S7 Edge - Other Phones might have a different storage path system. If you experience problems with my project please let me know)
An Example Project is attached
This is just a quick solution {TreeString} fix. Maybe there is a better way