If you locked your keys in the trunk, the standard procedure is to open the cabin first, then release the trunk from inside via the button on the floor, dashboard, or key fob inside the cabin.
Older vehicles (pre-2010) often had a separate trunk key cylinder that could be picked directly. Most modern vehicles deleted that cylinder to reduce theft risk.
If your vehicle has a fold-down rear seat with trunk access, the cabin can be opened and the seat folded to reach the trunk without using any trunk release button.
If neither approach works (rare in modern cars), the trunk may need to be opened via the emergency release inside the trunk — but that's only accessible from inside the trunk, which we can't reach if it's locked.
In genuinely stuck scenarios, removing a rear interior panel and accessing the lock mechanism mechanically is possible but tedious. Usually we get into the cabin in 10 minutes and the trunk follows immediately.