There are three reasons you might say not guilty: You didn’t do what the police say you did. You had a proper reason for breaking the law, like self-defence. You want the police to bring evidence to court to prove that you broke the law.
Most people have to come back to court a few times before their court case is finished. Some court cases can take up to 2 years.