The difference is that one is the subway system of Madrid and the other is a commuter train which goes outside of Madrid. The Metro has many many stops very close together. The Cercanias has many fewer stops and is a much faster train (so a local v. an express).