If the shift lever cannot be moved from the P (Park) position into R (Reverse) position with the brake pedal depressed, continue depressing the brake, and then do the following:
1. Place the ignition switch in the LOCK/OFF position.
2. Apply the parking brake.
3. Carefully remove the cap (1) covering the shift-lock release access hole.
4. Insert a tool (e.g. flathead screwdriver) into the access hole and press down on the tool.
5. Move the shift lever.
6. Remove the tool from the shiftlock override access hole then install the cap.
If you need to use the shift-lock release, have your vehicle inspected by an authorized HYUNDAI dealer immediately.
Hyundai Sonata LF 2014-2019 Service Manual: Hood Assembly Components and Components Location
Component Location
1. Hood assembly
...
Hyundai Sonata LF 2014-2019 Service Manual: Stop Lamp Switch Description and Operation
Description
The stop lamp switch plays the role of supplying signals to
turn on stop lamps and convenience devices (HECU,ECU,BCM,SMK etc.) for
drivers as a system that expresses the driver's intentions to brake by
pressing the brake pedal.
...