No, changes should be allowed.
Where do you see that locations can't be turned off, because the slider is grayed out? On Settings>Privacy>Locations?
Have you checked your "System Services" settings (scrolling down to the bottom)?
Have you already tried a forced restart of your iPhone?
- On an iPhone X, iPhone 8, or iPhone 8 Plus: Press and quickly release the Volume Up button. Press and quickly release the Volume Down button. Then, press and hold the Side button until you see the Apple logo.
- On an iPhone 7 or iPhone 7 Plus: Press and hold both the Side and Volume Down buttons for at least 10 seconds, until you see the Apple logo.
- On an iPhone 6s and earlier, iPad, or iPod touch: Press and hold both the Home and the Top (or Side) buttons for at least 10 seconds, until you see the Apple logo.
What iphone do you have? with what iOS version?
Regards
Giulio