The N/ui/dialog module is intended for showing dismissable messages, and won’t really work for progress bars as you cannot hide the buttons, nor close it via code. I would recommend looking at a third party library. A very popular one is SweetAlert2, and there is some sample code on the NetSuite Professionals site for using it with NetSuite. If you just want a quick hack, you could just used the Ext.js library that NetSuite includes by default on all pages.
Note: However I would highly recommend not doing so for any production code because NetSuite could update or remove it at any time in a future upgrade. In the 2024.2 NetSuite release, this feature will be deprecated.

Ext.MessageBox.show({
title: 'Lines are being copied...',
msg: 'This may take a couple minutes',
wait: true,
width: 250
});
// your work here
messageBox.hide()