Add static route with Ansible
Solution 1:
AFAIK, you're stuck using the command module to make your change using a shell command.
Solution 2:
net_static_route is available since ansible 2.4.
Depending on your requirements it might provide what you need.