The word anime comes from the word "animation", but it is used to be mean Japanese animation. While "anime" is simply Japanese cartoons, we use the word "anime" because of how vastly different anime is versus cartoons. The differences include the target age ranges, the types and complexity of plots, culture differences and art style.
Cartoons are generally geared towards children, with the exception of adult humor shows such as Family Guy, The Simpsons and a few others on Cartoon Network's Adult Swim. Anime on the other hand does have anime geared towards children, but as a whole, anime is geared towards all age, from children to adults, with a wide range of anime to choose from. Since cartoons are generally geared to children they tend to contain simple plots that allow children to easily understand it thereby being able to enjoy it more.
Most cartoons are episodic, what happens in one episode doesn't generally carry over into any other episodes, a character might die and be alive again the next episode. Cartoons tend to stick to simple humor with no central plot, though there are a few exemptions (such as the old Batman series). Anime on the other hand tends to be more serious in nature, can also contain humor but are more focused on a defined plot. Most cartoons also seem to lack character development, and this lack of depth is probably what makes cartoons "childish". As always there are exemptions, such as anime based off of Yonkoma Manga tend to have simple or no plot and little character development.
Culture differences are another thing that set both anime and cartoons apart, there are many things that may be accepted in Japanese culture, and therefore be in anime, that may be either censored or flat-out banned in American/Western culture. Things like homosexual relationships (yuri/yaoi), large age gap relationships (shotacon/lolicon) and incest relationships are allowed in anime while these are things you would never find in cartoons and would be banned or censored from the anime if brought over.