Inspector doesn't display my struct

This is my code:

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Test : MonoBehaviour
{
    // Start is called before the first frame update
    [System.Serializable]
    public struct TestField
    {
        int a, b;
    }
    [SerializeField] TestField t;
    void Start()
    {
       
    }

    // Update is called once per frame
    void Update()
    {
       
    }
}

In C# struct members are private by default.

Make them public if you want to see them in Unity, or else use a [SerializeField] decorator.

Before you venture too much deeper into struct usage, be sure you understand the distinction between Value Types and Reference Types or you are going to observe a lot of really baffling behavior.

To expand on what Kurt mentioned above, you should review the Unity Serialization Rules to understand what you need to get things to serialize in Unity.