When you use the editor you are writing code to a file. This file is then interpreted and run when you either type "irb myfile.rb" (for ruby) or "rails server" (for rails)
When you use the console you are typing code directly in to be run and interpreted as soon as you hit "enter".
There are two kinds of consoles. "irb" is the ruby console. You can type ruby commands in here.
"rails console" is the rails equivalent. You can type ruby in here also, but rails console also loads rails and all of the gems associated with rails as well as the gems in your Gemfile. so you can type rails commands in here as well and play with rails objects like the activemodel, etc.
Usually the text editor is for writing code that you want to be able to run over and over again. A computer program is usually something you want to be able to re-use. So you would write it in a text editor to be run and interpreted again later.
Usually the console is used to test things. I find the console very useful for this. You can open it up and just test to see how a certain command works. For instance if you wanted to play around with how the map method works for arrays. You can open up a console and create an array object, and send it the map message with different arguments to see what it does. The great thing about the console is instant feedback. You can see what you did and what happened because of what you did.
As soon as you leave the console (by typing "exit"), any code you typed in the console is lost and cannot be re-run without typing it all over again.
Let me know if you have any questions about this!