Lean can and does have bugs. It compiling doesn't mean anything, because that doesn't tell you whether the proof actually encodes what the mathematician intended. Plus, again, there can be prover bugs.