How to control an object in a specific area

I am trying to make a ball that can be controlled on the X and Y axis with the arrow keys on a certain plane, but when it touches the adjacent plane, you lose control of the ball. The ball keeps its momentum and continues to roll, however.

I am very new to Unity and C#, with only a small introduction to JavaScript as experience. It would be a great help if someone could teach me how to do this. Thanks in advance!

Use a boolean to determine if the player can control the ball or not.

When the ball collides with the plane, then switch the boolean so that the player can no longer input commands.

The engine physics will take over from that point and the ball will resolve without Player input.