Let f be a functor from the category C into the category D. If X and Y are objects in C, with a morphism from X to Y, then there is a morphism in D from f(X) to f(Y), and the functor implies a correspondence between the morphism from X to Y and the morphism from f(X) to f(Y). In other words, the functor carries objects to objects and morphisms to morphisms, so that the diagram commutes.
A functor must be compatible with composition. Consider the objects X Y and Z in C. A morphism from X to Y, and a morphism from Y to Z, implies a specific morphism from X to Z. This is usually function composition in a concrete category. Apply f, and find three objects and three morphisms in D. The third morphism in D must be the composition of the first two morphisms in D. This usually follows, in a natural way, from the construction of f, but you should always take a moment to prove it.
Algebraic topology is full of functors. The most familiar is the fundamental group of a topological space.
When inclusion corresponds to inclusion (covariant), or containment (contravariant), composition is never a problem. More generally, if there is at most one morphism between any two objects, then the morphism from X to Z maps to the only possible morphism from f(X) to f(Z), which is the correct one, as dictated by composition.
There is so much more to say about functors, but category theory is not my forte. In most branches of mathematics, you only need a working understanding of a covariant or contravariant functor to get by. So I will leave this topic be for now.