title: How to create a root folder in internal memory in android 10 (android studio)
body: <p>I need to create a folder (can be a file ) in internal storage in android 10. I just need the absolute path of the folder that was created previously so I can write files there. What is the internal storage root directory? Suppose that this is my internal dir:</p>
  <pre><code>android
  awsfolder
  booksfolder
  </code></pre>
  <p>So this is the root. I need to create a folder here, not in <code>android-&gt;data-&gt;com.mycompany.myapp-&gt;(not here)</code>. I have tried following to achieve it:</p>
  <ul>
  <li><p>config legacy storage supports to true in mainfest</p>
  </li>
  <li><p><code>getFilesDir()</code>, <code>getDir()</code> : it properly works in android 10 but it creates folder and file in <code>android-&gt;data-&gt;com.mycompany.myapp-&gt;here</code></p>
  </li>
  <li><p><code>getExternalStorageDirectory()</code>: it works perfectly in lower android like 7,8 and 9 also creates a folder in root but it is not working in android 10 (getting error no such a file and folder )</p>
  </li>
  </ul>
  <p>I don't need a cache dir using <code>getCacheDir()</code> and <code>getExternalCacheDir()</code>.</p>