Your app does not have the privileges to control other apps or the android system. This is a wanted feature as it is a malicious behaviour (malware). Only the system apps/services are allowed to do that (like from Android 6 you can revoke/add permissions via system settings like internet access). Main goal is that the user/ownner of the device has control over it.