A habitat and the organisms therein can be called an ecosystem. An ecosystem is basically a world - it can be really tiny, like a small area of water, or a huge area of land. Anything that damages either the habitat or the beings that live within it will damage the whole ecosystem. You can learn more about this concept here.