What exactly are you expecting to happen here? (I'm changing the indenting some to make the structure more obvious, and I'm adding line numbers for the sake of discussion)
01 if (incomingByte == 'C')
04 Console.println("Type tone in Hz");
05 incomingByte = 0;
06 while(incomingByte != '0')
08 incomingByte = Console.read();
09 if (incomingByte != '0')
11 var = Console.read();
12 tone(9, var);
Let's look at what it actually does:
Line 01: You're checking for a 'C' command, so far, so good.
Line 03: Stop any pending tone, makes sense.
Line 04: Prompt for additional data
Line 05: Clear out incomingByte
Line 06: Perform the next code block (lines 7 through 13) as long as incomingByte is not the ASCII character zero.
Line 08: Read a byte from the input stream, or get a NULL if no data is available.
Line 09: Is the character that was just read something other than the ASCII character zero? (Note, this is NOT checking for the binary value zero (NULL) which would indicate no character read.)
Line 11: Read another byte from the input stream, or get a NULL if no data is available, assign that byte to var.
Line 12: Use the ASCII character value as a number, and generate a tone at that frequency.
There are a bunch of problems here. The value read in line 8 is used for the test in the next line, but is not otherwise used to build your frequency. So, the first character you type in response to the prompt is not actually used. If you type a zero character on the keyboard, you'll skip lines 11 and 12, and you'll loop back to line 6, and the loop will be broken because incoming byte is now '0'. If you type any other character, the next character will be read and used as a frequency. But it will use the binary equivalent of the ASCII character: if you type '5', for example, it has an ASCII value of 0x35 or 53 decimal, so you will end up generating a 53 Hz tone. Then, the next character will be used to check for the '0' value to break the loop, and if you type anything other than '0' you'll take the next character and again generate a new tone with the corresponding value.
I'm sure this is nothing close to what you want. I assume that you want to prompt for a value, enter a series of digits until some terminator, and then convert that string of digits to a frequency value and generate a tone based on that.
You will need to change your loop to keep reading characters and place them in a buffer, until you get a terminator like a carriage return. You will need to make sure you look for NULL character values that mean no character yet available (and don't use that as the end of value terminator!)
You may have some success using readStringUntil() to read characters up until the terminator character.
Robin2 also has a nice tutorial on reading serial data: Serial Input Basics. It deals with the serial port, but since the Serial class and the Console class both derive from the Stream class, and the functions he's using to read from the serial port are the same functions available with the Console class, his examples should be directly applicable. (However, serialEvent() is NOT applicable.)