This is a perennial question when crocheting, and one that is not always satisfactorily solved. One method is to keep each color of yarn in a shoe box, in the correct order, and to turn the box in the same direction as you turn your work at the end of each row.
Contrary to the usual advice always to turn your work in the same direction when you are crocheting, turn it in opposite directions at the end of each row so that the ends of yarn are not constantly twisting around each other.
You may find that balls of yarn roll around the floor. You can either keep each ball in a jar, which has the added advantage of keeping it clean, or place it on a stick similar to that used for holding rolls of paper towel.
Another method of stopping balls of yarn from rolling around is to take the yarn from the middle of the ball. If this is difficult to find, rewind the ball with a wool winder. Taking yarn from the middle of the ball also gives you a more even tension.
A method familiar to knitters is to wind short lengths of yarn onto bobbins. Because of the simplicity in joining on new colors, this method works especially well in crochet.