Real Madrid fikk det tøft mot bynabo Rayo Vallecano og klarte ikke å ta tilbake tabeltoppen fra Barcelona.