Multilayered cellular automata in modeling biological systems