ASX Close: Market ends slightly in the red