The code that you have found is not part of the Kendo.Mvc.dll and the Queryable extensions. They are a community effort and largely experimental as noted in the README.md
The ToDataSourceResult() extension method is designed to work with the built-in transports in ASP.NET MVC & ASP.NET Core and the source code is available in the accounts of licenced users when they navigate to the Downloads section.
It appears that you are testing out the jQuery Kendo UI Grid and using of the server-side extensions is not required. You can format your own response and structure the grid data source in such way that it can parse it.
We have a runnable example in a sample Knowledge Base that can help you format the group response here:
Here is another forum post that shows that:
Let us know in case you have further questions.