Just because you're telling the truth doesn't mean that they'll present it to the court in a way that makes it seem like the truth. If they want to convict you, witnesses will show up pinning you to the crime. That, or they'll use "interrogation" tactics to get you to "confess" when you're innocent. It's mindgames to close the case early. The U.S. has a worrying amount of wrongful convictions, for many reasons.
To sum it up: never speak to police without a lawyer.