Most "Stop and Identify" Laws in the U.S. only give police the power to require you to provide identification, only if they have a reasonable suspicion that you have committed a crime.
https://en.wikipedia.org/wiki/Stop_and_identify_statutes
If I were stopped by police I would just politely ask "Have I done anything wrong?". If they then tell you that you were stopped for "...possible violation of law xyz..." then I would not refuse to provide identification. That alone could get you arrested. Once you have provided identification and they continue to question you I would just say "...am I under arrest?..." If they say no, then respond "Well have a good day." Certainly do not consent to them coming inside your apartment/hotel/etc. for possible search and further questioning.
https://en.wikipedia.org/wiki/Stop_and_identify_statutes
If I were stopped by police I would just politely ask "Have I done anything wrong?". If they then tell you that you were stopped for "...possible violation of law xyz..." then I would not refuse to provide identification. That alone could get you arrested. Once you have provided identification and they continue to question you I would just say "...am I under arrest?..." If they say no, then respond "Well have a good day." Certainly do not consent to them coming inside your apartment/hotel/etc. for possible search and further questioning.