My question is how the three sides don't contribute any flux whereas we can see that a small fraction amount of flux can pass through the three sides.
Not really. You see, the electrostatic field $\vec{E}$ of the charge is always radially outwards. If the charge is situated at the exact corner of the cube, then the field is exactly coplanar with the three faces passing through that corner. What I mean, is that the field doesn't cross any of these 3 faces. And that means, the flux of the electric field through these 3 surfaces is 0. (Because, $\vec{E}$ and $\vec{dA}$ are perpendicular and so $\vec{E}\dot{}\vec{dA} = 0$)
Now, consider a bigger cube, with each edge twice as long as the given cube's, with its center at the charge itself. It is not difficult to realise that this cube can be decomposed into 8 cubes, of smaller size, each with the charge at one corner. Also, all of these cubes are perfectly symmetric, in the sense that the flux through each of them is the same. On the other hand, the flux through the whole of the bigger cube is $\frac{q}{\epsilon_0}$, as provided by Gauss's Law. Hence, we can conclude that the flux through the given cube is exactly $\frac{1}{8}$-th of the total flux of the field through the bigger cube, id est, $\frac{q}{8\epsilon_0}$. Because flux through the adjacent 3 faces are 0, the flux through each of the remaining has to be $\frac{1}{3}$-rd of this flux, because these sides are also perfectly symmetric.
The answer to the question comes out to be $\frac{q}{24\epsilon_0}$.
If the charge were not exactly at the corner, the situation would have differed. If it were slightly outside the cube but nearly at the corner, the flux through the distant 3 faces would remain unchanged ($\frac{q}{8\epsilon_0}$) whereas the flux through the 3 close-by faces would be the negative of that because the net flux through the cube has to be 0. (There is no charge in it now.)
If the charge were just inside the cube but nearly at the corner, then too the flux through the 3 distant faces would remain unchanged, but now the net flux through the cube has to be $\frac{q}{\epsilon_0}$ so the flux through the three adjacent sides would be $\frac{7q}{8\epsilon_0}$.