There is little agreement over when or even if Moses led the Israelites out of Egypt. Biblical scholars have extrapolated a date between 1500-1400 BC but there is no mention in any Egyptian source of the Israelites having ever been in Egypt in the first place.
Nevertheless, in Exodus we find the earliest Biblical reference to excretion and, perhaps appropriately, it involves the Pharaoh rather than the chosen people. The sophistication of Egyptian culture is well-known but plumbing and sanitation was not their strongest suit. There is some evidence for earth closets and chamber pots being used during the 18th Dynasty (1550-1292 BC) but, as the following passage suggests, at the time of the exodus the Pharaoh was still using more natural methods.
Get thee unto Pharaoh in the morning; lo, he goeth out unto the water; and thou shalt stand by the river’s brink against he come; and the rod which was turned to a serpent shalt thou take in thine hand.
Faced with the Pharaoh’s pig-headedness, Moses is told to tackle him while he was easing himself in the Nile. Rather than defecating on the river bank, it is thought that the Pharaoh could not be seen to be performing such a common task and so he would go into the water to cover his actions. He is at his most vulnerable; an ideal time for Moses to lobby him. The plague that is unleashed - turning the waters to blood, killing the fish and making the river stink - was presumably twice as impressive when the Pharaoh was squatting in the shallows.