✅ Inherited a class but the compiler does not accept it? - C#