Check the loom of wires inside the trunk by the driver's side trunk hinge. Open up that loom and look for freyed or broken wires. I suspect you will find bare wires inside there with 1 or more of them contacting the brake light wiring. Fix what you find with electrical tape.
Mike