Quilt it first, then put the pocket on. Add a flap that closes with either velcro or a snap. Putting it in the corner and sew it down with the binding and that will take care of 2 sides. I would probably sew the other side by machine to make it sturdier and just sew thru all of the layers.