It's more of a thought experiment, and doesn't involve any actual geometrical calculations of the resonator. The shape isnt mentioned, just that it's a container filled with thermal photons, and there exists a hole which looks into that container.
A cube would probably be easier, if you wanted to include actual calculations of modes and reflections. If you like, suppose the opening is perfectly focused with telescopic optics, and angled at a transcendental angle (i.e., tan(angle) is not a rational number) so it undergoes infinite reflections within the box.
That's a very roundabout way of simply willing it into being: that there is some sort of chamber, which exhibits a series of modes, and that the viewport somehow experiences the thermal equilibrium of those modes. Physicists are great at making up s%!t like that. :-)
Yup. The best "blacks" take advantage of the residual reflectance of the surface, using the "stack of razor blades" effect to trap glancing reflections ever deeper within the surface. And then making a cavity out of that, so there really isn't hardly anything that's getting back out in a non-thermal manner.
The ideal cavity has a fractal structure, something like a Koch snowflake with a bit steeper angles on the faces to better trap the radiation. Of course, the nano scale "black" materials do this to the lowest of scales, so they're quite good even without the larger structure.
Tim