In newer versions of Minecraft: Java Edition, the ability was added to navigate around in-game menus using your keyboard by using the Tab key and pressing Enter to select the highlighted option. If you click on the GUI Scale setting to change your GUI size, it works as intended. However, using your keyboard instead will change the setting, but not update your GUI Scale.
Brief video of this (I uploaded it to YouTube because it's larger than 10MB, sorry!): https://www.youtube.com/watch?v=g-sBAM7De0A
Thank you for your report!
We're actually already tracking this issue in MC-166361, so I resolved and linked this ticket as a duplicate.
If you would like to add a vote and any extra information to the main ticket it would be appreciated.
If you haven't already, you might like to make use of the search feature in the future to see if the issue has already been reported.
Quick Links:
📓 Issue Guidelines – 💬 Community Support – 📧 Customer Support – 📖 Game Wiki