To keep track of cart data, WooCommerce makes use of 3 cookies:
The first two cookies contain information about the cart as a whole and helps WooCommerce know when the cart data changes. The final cookie (wp_woocommerce_session_) contains a unique code for each customer so that it knows where to find the cart data in the database for each customer. No personal information is stored within these cookies.
So, when enable varnish, please exclude WooCommerce these 3 cookies for Varnish.