Sounds like a lot of work and money if you're only going to use it for mash out... IMO, it's a whole lot easier to just mash out with boiling water, then you need a smaller quantity and you also don't have any trouble hitting exactly the right temp.
Or did you mean to say sparge water?
It is not difficult to mount a hot water heater element into a container. They come with a rubber gasket, and you can go to the electrical conduit section of home depot (or wherever) and get a 1" threaded locknut (which is a match for the heating element threads). Drill a hole, stick the element through, throw on the gasket, and crank down the locknut. Smear the whole deal with silicone before and after mounting for an even better seal. In a cooler, you'll probably want to cut away the outer wall and insulation around the area so you're bolting the element into only the inner wall.
With that said, like any electric water heating project used in brewing, it is NOT a great thing to tackle if you are not experienced enough with electrical safety. A couple thousand watts of electrical power, plus lots of heat in close vicinity to plastic, plus DIY mounting and seals being the only thing keeping water from reaching your DIY wiring, all adds up to a pretty dangerous combination if you don't do things correctly. No matter what you do, don't even CONSIDER skipping the use of a GFCI. I have no idea what your actual skill level is, but just take this as a disclaimer regardless.