Multilayer Network Model of Gender Bias and Homophily in Hierarchical Structures