Fiber isn't digested therefore will pass right through which is why green vegetables are ok to eat on a keto diet. Don't try to cheat the system however and sneak some carbs that you assume are mostly fiber. Beans are very high in fiber but I guarantee if you start fooling around with foods like this thinking you're under the magic 30g of carb limit then you're going to knock yourself out of ketosis and screw yourself up.