I've created a few digital products, for which I am the sole developer; I also handle all customer service related to those products.
I've found that the best time to ask customers for a 5 star review of my product is just after I solve their problem over a customer service channel, which in my case typically occurs over Zoom or email.
Why does this work?
Just an assumption but I think customers are more likely to take action (leaving a review in this case) just after you solve their problem because they're buzzing from the good feelings produced by the removal of what used to be some type of pain point.
Delight your customers; then ask for a (highest rating possible) review and most of the time you'll get it.
Best