Had The Same Problem...
That problem was a pain because it drained my battery of course...
There's a small plastic 'stopper' which has more than likely broken out. A hole in the metal lever just behind the brake pedal is where the 'stopper' is supposed to be.
The stopper would go thru that hole and press against a switch aimed at it, which controls the brake lights coming on and off when the pedal is pressed.
Get underneath the dash, press the pedal and follow the mechanics...it's hard to miss. I had to use a door panel plug to depress thru that hole until I found a more suitable application.... Hope this helps.
Adrian