There are plenty of existing guides for doing this.
Add updates to a Windows image
docs.microsoft.com
Automating the install process is quite a bit more technical (all of which is documented on docs.microsoft.com
Answer files (unattend.xml
docs.microsoft.com
Windows Setup Installation Process
docs.microsoft.com