Can I write my own custom editor code using Odin?

This is possible, yes - you should in this case inherit from OdinEditor instead of Editor, and then use Odin's own property system to draw instead of Unity's. In Odin, the PropertyTree and InspectorProperty types correspond to respectively Unity's SerializedObject and SerializedProperty types, and provide similar functionality.

For example, your custom editor might look like this:

[CustomEditor(typeof(MyMonoBehaviour))]
public class CustomOdinEditor : OdinEditor
{
    public override void OnInspectorGUI()
    {
        var tree = this.Tree;                                      // Like this.serializedObject.
        var obj = this.target as MyMonoBehaviour;
 
        InspectorUtilities.BeginDrawPropertyTree(tree, true);      // This and EndDrawPropertyTree automatically handles a lot of stuff like prefab instance modifications and undo
 
        if (obj.SomeCondition)
        {
            var someProp1 = tree.GetPropertyAtPath("someProp1");   // Like serializedObject.FindProperty("path")
            someProp1.Draw();                                      // Like EditorGUILayout.PropertyField(property);
        }
        else
        {
            var someProp2 = tree.GetPropertyAtPath("someProp2");
            someProp2.Draw(new GUIContent("My Label"));            // You can also pass custom labels into Draw()
        }
 
        InspectorUtilities.EndDrawPropertyTree(tree);

        // You can also call base.OnInspectorGUI(); instead if you simply want to prepend or append GUI to the editor.
    }
}
In fact, you can draw the entire tree "as usual", IE the default Odin inspector, merely by calling tree.Draw(), which draws all the root level properties of the tree - that is exactly how Odin renders the full default inspector.
Can I use Odin for its editors only, without using the serialization? Can I use Odin for its editors only, without using the serialization?
Can I use Odin to make inspectors for my own asset store plugins? Can I use Odin to make inspectors for my own asset store plugins?
Can I use Odin Inspector to create custom editor windows? Can I use Odin Inspector to create custom editor windows?
Does the serialization support Windows Store and UWP? Does the serialization support Windows Store and UWP?
How do I contact Sirenix to report bugs, suggest features, or in general? How do I contact Sirenix to report bugs, suggest features, or in general?
Does Odin support serialization of Unity object references? Does Odin support serialization of Unity object references?
Does Odin support interfaces? Does Odin support interfaces?
How can I add an image to the inspector? How can I add an image to the inspector?
Why isn’t Odin drawing the inspector for my script? Why isn’t Odin drawing the inspector for my script?
Why is Odin not serializing or showing my field or property? Why is Odin not serializing or showing my field or property?
How will Odin handle existing editors? How will Odin handle existing editors?
How can I make a list show one item per page? How can I make a list show one item per page?
Does Odin support cross scene references? Does Odin support cross scene references?
Can I disable or hide an inspector property in play mode, or vice versa? Can I disable or hide an inspector property in play mode, or vice versa?
Which platforms are supported by Odin? Which platforms are supported by Odin?
How easy is Odin to uninstall? How easy is Odin to uninstall?
How will Odin affect performance in the inspector? How will Odin affect performance in the inspector?
How can I make my data in Odin Editor Windows persistent? How can I make my data in Odin Editor Windows persistent?
Unity crashed, could this have something to do with Odin? Unity crashed, could this have something to do with Odin?
How can I show static fields and properties in the inspector? How can I show static fields and properties in the inspector?
Can I use Odin's serialization without inheriting from SerializedMonoBehaviour etc.? Can I use Odin's serialization without inheriting from SerializedMonoBehaviour etc.?
How fast is Odin's Serialization system? How fast is Odin's Serialization system?
How stable/reliable is Odin's serialization system? Can I safely use it in my project? How stable/reliable is Odin's serialization system? Can I safely use it in my project?
Is it possible to customize how the dictionary drawer draw its key-type using attributes? Is it possible to customize how the dictionary drawer draw its key-type using attributes?
How can I make an attribute that lets you drag elements unto a member to set its value? How can I make an attribute that lets you drag elements unto a member to set its value?
Why are my values disappearing when I hit play? Why are my values disappearing when I hit play?
Why is there a Serializable JSON Dictionary in my Odin Editor Window? Why is there a Serializable JSON Dictionary in my Odin Editor Window?
How can I rename a type without loosing data? How can I rename a type without loosing data?