Containers such as chests are locked upon placing them, you can share your containers by using /cmodify (playername) and punching it. You can add multiple players at once by putting a space between each playername. Furthermore, if you want to allow the person to break the container, you can set them as a container owner using /cmodify @(playername) instead. If you want to share all your locked containers with another player at once, you can use /trust (playername)