How does a court determine if the confession or statement is given voluntarily?
If the statement or confession is being provided by someone who has been arrested, then the Court first must ascertain whether or not the person has been Mirandized (based on a case known as Miranda v. Arizona). The arresting officer must tell the suspect that anything he or she says can and will be used as evidence in court and that the suspect has the right to consult with an attorney before making a statement/confession. In addition, the suspect must affirmatively waive the rights conferred by the Miranda warning, as well as acknowledge that he or she understands the rights.
As long as the Court is satisfied that the person was properly Mirandized, the Court accepts the voluntary nature of statements or confessions.