Are you using ASP.NET Core of MVC 5 with .NET 4.8?
The documentation on widgets can be toggled between .NET Core and MVC 5.
Widgets with Controllers don't exist in ASP.NET Core development and have instead been replaced by using View Components.
If you are starting a new site/application, I strongly recommend using ASP.NET Core (either via .NET Core 3.1 or .NET 5) and avoiding any MVC 5 development on .NET 4.8.