You can open the Guild dialog by pressing CTRL+G or the Guild button under the Actions sidewindow when logged in to the game.
If you are not in a guild, you will be presented with a dialog where you can either create your own guild, or join an existing one if you have been invited by a guild leader. To join an existing guild, select your desired invite from the list and press "Join Guild". You will be a part of the guild immediately. If you want to create your own guild, enter the guild name into the name textbox and press Create. The name must be between 3 and 20 characters long and may only contain alphabetical characters, dashes and spaces. Creating a guild requires level 15+ and costs 10 premium cards, so take care with the choice of your guild's name! A character may only be a member in 1 guild at a time.
Be careful when joining existing guilds, as you might find yourself in the middle of a guild war!