title: Python discord bot leave voice channel
body: <p>I've made bot to join my voice server like below</p>
  
  <pre><code> if message.content.startswith("?join"):
      channel = message.author.voice.channel
      await channel.connect()
      await message.channel.send('bot joined')
  </code></pre>
  
  <p>but i can't make bot to leave the channel.. how can i code to do it??
  and what is the difference between</p>
  
  <pre><code>@bot.event
   async def on_message(message):
   if message.content.startswith('~'):
  </code></pre>
  
  <p>and</p>
  
  <pre><code>@bot.command()
  async def ~(ctx):
  </code></pre>