Suicide is certainly legal. You cannot be arrested or imprisoned for trying to take your own life for the very good reason that it is your own life and up to you what you do with it. However if you try to kill yourself, fail and are taken to hospital you will almost certainly be sectioned under the mental health act, for a limited time period while doctors try to "make you better". Sections are rarely indefinate lengths of time. The shortest is 72 hours, the longest is a year, however the psychatrists will review your progress during this time and can extend it. You can only be held indefinately under the mental health act if you are criminally insane - ie you are a danger to others. Generally, suicidal people are only dangerous to themselves!