Check cookie before using back-end server

When HAproxy redirect request to the backend server, can it check the request header include a cookie?
If there is no such cookie, it will not access the backend server and redirect to another backend server
It just need to check the name of cookie exist, no need to check the cookie value