If you're not actually committing a crime. Then yes if they just stop you and request ID you CAN refuse.
If they say there gonna arrest you then still refuse to ID and let them take you to Jail.
You'll certainly be released within an hour without even being booked or any charges filed.
Because it is NOT against the law to refuse to ID yourself when not committing a crime.