I have downloaded and fully synced with my Mac last Saturday, my Bitcoin Core version is v0.21.0 and my Bitcoin-Qt version 5.9.8.
I did run other RPC commands such as "getrpcinfo" and it did provide result:
{ "active_commands": [ { "method": "getrpcinfo", "duration": 72 } ], "logpath": "/Users/jsjs77/Library/Application Support/Bitcoin/debug.log" }
"getbalance" -  { "mine": { "trusted": 0.00000000, "untrusted_pending": 0.00000000, "immature": 0.00000000 } }
But then, when I want to run this "generatetoaddress nblocks "address" it does not provide block hash result:  generatetoaddress 11 1MDihWw2UfkYyAwrQDWNFbmaH6bx4NBFtL
 [
]
I have tried the following methods:
bitcoin-cli generatetoaddress 11 1MDihWw2UfkYyAwrQDWNFbmaH6bx4NBFtL.
 Method not found (code -32601)
and
bitcoin-cli -regtest generatetoaddress 11 1MDihWw2UfkYyAwrQDWNFbmaH6bx4NBFtL
Method not found (code -32601)
Is this got to do with the changes of latest version? I really need help. Thanks