while you can use any object as the view model passed to a view, the post back model must support serialization via json, or binding via the form post fields. A DataTable can be used for form post view model.
change edit to:
public IActionResult edit(IFormCollection form)
in the view, you need to render the table data with form field with a name. say:
<form>
<table>
@for (var i=0; i < Model.Rows.Count; ++i)
{
var row = Model.Rows[i];
<tr>
@foreach(var c in Model.Columns)
{
<td>
<input type="text"
name="@$"{c.ColumnName}[{i}]""
value="@row[c]" />
</td>
}
</tr>
}
<tr><td><button type="submit>Post</button></td></tr>
</form>