The simplest latch is like that found on many southern mountain rifles...a springy "nail" set into the cavity that just catches the box lid at the back end. that way, you don't need to alter the lid in any way.
Otherwise, it is necessary to file out a peg that is riveted and soldered to the lid and which has a notch in it to catch a spring loaded hook set into the end grain of the butt stock. With this method, you also have to incorporate a release system, ie: a push rod from either the heel of the butt plate of the toe plate along the bottom of the stock. And that means drilling a hole through the stock from either the top or bottom to align with the catch.
With any system, it is best to also include a kick spring that puts the lid under tension when it is closed, so that when you release the lid, the lib flips open by the action of the internal spring.
A third system is a camming spring mounted under the head of the patch box that presses on a piece of metal soldered to the underside of the lid. To open this lid, which is kept shut by the pressure of that spring under the head of the box, you insert your fingernail into a recess filed into the butt plate and lift up on the box lid which when it reaches a certain point, will snap open by the pressure of the spring having come past the balance point.
Noe of this is difficult to do, but it is usually done while the gun is being buit, not after it is finished. So good luck - it's not impossible.