Well, for one, foods aren't the only thing that affect symptoms. And a lot of food issues are related to (1) which parts of your GI tract are affected and (2) what's wrong with them. People with strictures usually need to eat low-fiber diets, for example, but people without structures can actually benefit from some fiber.
The "why" is a little less clear, but it's likely a mix of genetic factors and environmental/infectious triggers. Plus good old-fashioned stress :)