Hi,
Secure erase is NOT something you typically need to do. I would reserve it for a drive that has been heavily abused, or whos performance has severely diminished, bad cells, etc.
Like a standard disk, m.2 drives can be partitioned and formatted using diskpart or GParted. If you want to secure erase your drive because someone told you to do so, maybe you should determine if the service is truly needed. If the drive is performing within spec then delete your partition(s), create new one(s) format and install.
Can you remove it from the board while the board is powered, yes, but its a sensitive electrical component and you will run the risk of damaging it or your board. My advice, if the drive is not operating properly, you should use its warranty.