4.05
(a) The offensive team shall station two base coaches on the field during its term at bat, one near first base and one near third base.
(b) Base coaches shall be limited to two in number and shall (1) be in team uniform, and (2) remain within the coach’s box at all times.

PENALTY: The offending base coach shall be removed from the game, and shall leave the playing field.

Link

Yeah…so, apparently one of the unwritten rules is to ignore this very written rule.  Also, the typo in it.

The most hilarious part…  the “comment” that MLB gives the rule.

Rule 4.05 Comment: It has been common practice for many years for some coaches to put one foot outside the coach’s box or stand astride or otherwise be slightly outside the coaching box lines.

Um…slightly outside?  Wait, wha…?  If slightly outside the third base coach’s box means closer to the first base coach’s box, then Tim Flannery was obeying the rules.

That box serves about as much use as leg bones in whales.