Witnesses have to swear to tell the truth during the trial. If a witness lies in court, it is known as "perjury", which is a crime. A witness can be subpoenad, which means they are required to testify in court. If the witness does not testify when given a subpoena, they can be punished.