There are several mechanisms you can use to block IP addresses, none of which should necessarily be limited by memory.
That said, operationally speaking, having thousands of objects for IPs you want to block is probably not the right approach.
Not to mention every time you add such an IP, you'd have to push Access Policy.
You might want to explore some of the options here, none of which involve creating objects, but does involve CLI commands: https://community.checkpoint.com/t5/Threat-Prevention/Blocking-IP-address/m-p/34587#M1048
You can also use the ioc_feeds feature to have Threat Prevention block the IPs: https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solut...
For R81 gateways, you might want to look into the Generic Data Center objects.
This will allow you to create a single object that's fed via a JSON file that can be hosted on any web server that the gateways will periodically pull and enforce without a policy installation.
https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solut...
Even without Generic Data Center objects, you can use a Dynamic Object to achieve something similar (requires CLI commands on each gateway to manipulate): https://supportcenter.checkpoint.com/supportcenter/portal?eventSubmit_doGoviewsolutiondetails=&solut...
Lots of ways to approach this.