How can I get the bitcoin amount of an bitcoin address which doesn't belong to my wallet? I am trying to make a query about a bitcoin address's btc amount. As I've read, getreceivedbyaddress rpc command can only be used for the addresses of a wallet that one owns and that command is awallet command. I want to make a query about any bitcoin addresses btc amount. Is it possible? If yes, how do I do it?
You can use the new scantxoutset method to check for UTXOs matching a given script, address, or key descriptor.

For example, to scan an address, you can use:

bitcoin-cli scantxoutset start "[\"addr(1....)\"]"