Ensure if Onedrive is creating a random Uninstall string (detection Method)?
For example, if you install any standalone MSI applications, the uninstall string never change - HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall but few cloud applications may randomly generate the Uninstall string. In this case, we should not use this registry hive in detection method (Applications Model).
Pl check if you can install the Onedrive application using PsExec. if it works and above case is true as well, then go for Packages Model(i.e., No detection method profile)