You can glue one end of the plug to the inside of the magazine cap. That will keep the plug in place, but will it satisfy the law? You might have to drill out the magazine cap and use a screw to hold the plug or even use a metal tube plug and weld it to the magazine cap.
Another approach is to crimp the magazine tube to prevent the follower from moving more than a certain distance. The crimp is shallow enough not to interfere with the spring. That of course, is permanent; undoing it would require a new magazine tube.