To pick locks in Death Trash, you will need to get lockpicks, when you have them, picking locks is a matter of walking up and pressing interact on a lock container.
Doing so will have a certain chance to open the lock container depending on how much skill points you have in lockpicking.
The more skill points you have, the better your chances of unlocking the locked container. That said, You can get lockpicks either by finding the item as loot or by unlocking the crafting of lockpicks by getting a recipe for them in the game.
To get the recipe for lockpicks, you will need to find it. The best way is to find the recipe via containers.
Inside lootable lockers, you can sometimes find recipes to make lockpicks and other recipes. In other cases, you will need to check vendors for the recipe as sometimes merchants can sell other recipes as well.
Related: How to fast Travel in Death Trash?
However, before you are able to craft lockpicks, you will need to unlock crafting in general, which requires crafting knowledge. To get crafting knowledge, you will need to find a certain book that unlocks it for you.
You can find this book via a cave in the festering gorge, the vast area you find in the game outside of the first location. Inside this cave, you will find a body guarded by a bandit with a gun.
Kill the bandit, and you can find crafting knowledge on the dead body and potentially the recipe for lockpicks if you are lucky.
When you have both crafting knowledge and the lock pick recipe, click use on both, and you will unlock the ability to craft lockpicks for two mechanics.