Serializer class for YAML in C#