Binky, there have been threads on this in the past, but since you can’t search I’ll give a short answer to your inquiry.
If I’m representing a person accused of a criminal offence, I cannot mislead the court. It is my duty, however, to test the prosecution’s case. The accused does not have to prove that he didn’t do it. The onus is is the prosecution to prove, beyond a reasonable doubt, that the accused did it.
Suppose the client is charged with a mugging and admits to me that he did it. I can enter a not guilty plea on his behalf, because that isn’t a statement of fact. It’s saying to the Crown prosecutor, “Prove it!” However, since the accused has admitted to the mugging, I cannot lead any evidence to suggest that he was not present, such as an alibi. What I can do is test every aspect of the Crown’s case and see if there are any reasonable doubts.
So for example, I can cross-examine the person who was mugged to see if they can identify my client and whether they did so in proper controlled circumstances. What if it turns out that the victim is extremely near-sighted and had his glasses knocked off during the episode. How reliable is the eye-witness identification then? Or, if the assault occurred at night, were there any street lights around? If not, how can you be sure of the victim’s identification? Or, what if the police conducted the photo i.d. in a way that unfairly brought my clientto the victim’s attention, increasing the chances of an identification?
The Crown prosecutor’s onus is to rebut each and every one of these challenges. If my cross-examination of the victim on the identification, or of the police about the fairness of their procedures, raises a reasonable doubt in the mind of the jury (or judge, in a trial with judge alone), then the Crown has not met the onus and my client is entitled to an acquittal.
Why is that permitted? Because in liberal democracies we prize individual liberty so highly. We intentionally stack the deck in favour of the accused and against the state. We do so knowing that sometimes people will be acquitted who may be guilty, but we do so because it’s one of the best protections against a police state. A defence lawyer who does his or her job is working for the client, and also working to protect our system where the onus is always on the state to prove a case beyond a reasonable doubt. If the defence lawyer can poke enough holes in the Crown’s case to raise a reasonable doubt, then the client is entitled to an acquittal and the system has worked properly.