You can use class “table-bordered”.
Check the Showcase app for other useful classes: https://ux.mendix.com/theme-viewer.html?profile=desktop?theme=silver_linings (in the menu Design Elements > Tables.
You can write custom CSS styling for the default mx table class, else you can either add CSS directly in the style tab of widget. Something like border: 1px solid black;