I have two identical databases (in different servers that don't communicate to each other) and I need to duplicate some records from one server to another. I need to select the records from one server and insert in the other, meaning that it has to be done in two steps and therefore the command would have to select the records and kind of to generate an insert script.
The simplest solution I can think of would be SSIS, or even Import/Export wizard. In SSMS, right-click on the target database, select Tasks -> Import Data. A wizard dialog will walk you through the steps. You can select whole tables or views, or you can write queries to select a subset of records from a table or view.
SSMS = SQL Server Management Studio
SSIS = SQL Server Integration Services
SSMS is the tool you use to access SQL Server and execute queries, manage databases, tables, views, etc...
SSIS is a service that runs on a server that executes packages. SSIS packages are created using Visual Studio - specifically SSDT (SQL Server Data Tools).
If this is a one-time operation - use the Import/Export utility within SSMS. This is a wizard that builds and executes an SSIS package. If this needs to be repeatable - then you can build the package in SSDT and deploy it to an integration services catalog.
If you do not want to use SSIS - you can use Powershell. In Powershell - you would get the results into a variable using Invoke-SqlCmd - then foreach over each item in the result variable to build an insert statement - then use Invoke-SqlCmd to execute the insert statement on the destination.