Friedrich Engels owned a factory, making him a capitalist. Sure, it might not be the most ethical thing to do when you consider yourself a communist but it's not always that black and white. Also, you owning one appartment and renting it out for whatever reason will not make you comparable to big property owners that own 600 houses.
It's better not to own an appartment that you're only going to rent out though.