If you came to the United States on the Visa Waiver Program (VWP)—which is a simple option for people from many parts of the world, in particular most European countries—you likely enjoyed easy entry at the U.S. airport or other border post. The VWP allows people to avoid having to go to a U.S. consulate in their home country to apply for a nonimmigrant visa (such as a B-2 visitor visa) before traveling to the U.S. for short pleasure trips.
Use of the VWP for U.S. entry comes with strict conditions, however. You are, at this point, very limited in your immigration options if you'd like to stay in the United States longer or permanently. In particular, you are not allowed to change status within the United States, which is significant to would-be vocational students for the reasons described below.
A so-called "change of status" is pretty much the only procedural method for getting M-1 vocational student status while already in the United States.
Someone who arrives in the United States on an actual nonimmigrant visa (and doesn't overstay their permitted time in the U.S.) might be able to apply for the change of status using USCIS Form I-539. (Though if you had entered on a B visa for visitors, you would have had to indicate in advance that you'd be looking at schools, and gotten a "prospective student" notation in your visa in order to successfully apply for a change of status.)
But the change of status option is completely closed to people who entered the United States on the VWP. If you submit an I-539, it will be denied.
Your remaining options? The best one is to back to your home country and apply for an M-1 visa through the U.S. consulate there. Don't try to go to Mexico to get the M-1 visa (assuming that's not your home country): U.S. consulates there won't accept applications from third-country nationals who entered the U.S. on the VWP.
The U.S. consulate in Canada has no such blanket policy, but is very reluctant to process visa applications from non-Canadians, and might give your application a hard look even if it agrees to review it.
An experienced attorney can assist with the task of figuring out the fastest way for you to apply for an M-1 or other appropriate visa to the United States and help prepare the paperwork and keep your case on track.