Check out example codes for "resize form in C# winform". It will help you in understanding the concepts better.

Code Example 1

[DllImport("user32")]
private static extern bool ReleaseCapture();

[DllImport("user32")]
private static extern int SendMessage(IntPtr hWnd, int Msg, int wp, int lp);

public struct NCHITTEST
{
	public const int Left = 10;
	public const int Right = 11;
	public const int Top = 12;
	public const int TopLeft = 13;
	public const int TopRight = 14;
	public const int Bottom = 15;
	public const int BottomLeft = 16;
	public const int BottomRight = 17;
}

protected override void OnMouseDown(MouseEventArgs e)
{
  	base.OnMouseDown(e);
	if (e.Button == MouseButtons.Left)
    {
    	ReleaseCapture();
      
      	// for the 'wp' parameter, just replace 'BottomRight' with your direction
      	SendMessage(Handle, 161, NCHITTEST.BottomRight, 0);
    }
}

Learn ReactJs, React Native from akashmittal.com