What you eat has a real effect on how steadily you can concentrate, mainly because your brain runs on a stable supply of energy. The foods that help are the ones that release energy slowly and keep your blood sugar even, rather than spiking it and crashing it.
Good everyday choices include whole grains like oats and brown rice, eggs, nuts, seeds, fruits, vegetables, dal, curd, and enough water. Nuts and seeds give healthy fats that the brain likes, eggs and dal give protein that keeps you full and alert, and fruits give steady energy plus vitamins. Staying hydrated matters more than students expect, because even mild dehydration makes you feel foggy and tired.
The foods to be careful with are heavy sugar and refined snacks like sweets, sugary drinks, and lots of fried or maida based items. They give a quick rush followed by a crash that leaves you sleepy and unfocused about an hour later, which is the worst timing during a long study session. This does not mean you can never enjoy them, just do not rely on them as study fuel. A simple rule is to eat light before studying, because a very heavy meal pulls blood toward digestion and makes you drowsy.
Example: A handful of nuts and a fruit before studying keeps you alert far longer than a plate of sweets, which feels good for ten minutes and then makes you sleepy.
One practical tip: Keep a water bottle on your desk and finish it during each study session. Hydration is the cheapest focus booster there is.