More or less yes. But you'll need to set your audio interface buffer as low as you dare to avoid hearing your systems round trip latency. Not all audio interfaces are capable of low RTL.
Also your recorded track will not include the sound of your amp which for most of us is the most important component in a good guitar tone. You might as well use your studio monitors for the playback as that will be what the recorded track will sound like anyway.
To include your amps tone you mike it up or use it's DI output if it includes a speaker emulated output like some do.
You would use this as your guitar input source instead of plugging in directly. Plugging in directly can result in a very thin tone with some interfaces. Using an amp is the way a guitar was meant to be used. But some interfaces have pretty good instrument inputs that seem to work OK for Amp Sims.
You then have the option of recording the Amp dry and adding the effects after or hooking it up as your have done and miking the amp and record that to a new audio track. This is called Re Amping. But that track will need to be nudged in time to compensate for the latency if you do this live. If you record a dry guitar track and then re- amp there should be no latency.
It can work live with top shelf audio interfaces like RME.