I think you need to make a little project in Xcode to write a callKit extension.
That is a little app you embed within your Xojo app in the right place.
Then this little extension can use a SQLite database from the Xojo app to query the phone numbers as far as I know.
I believe you are right though that Apple does not allow these apps to make off-phone connections. Just about every call or text blocking app that I’ve seen utilizes an on-phone database that gets periodically updated.