input: Write a function to create a Flask application that allows submission of form data (Name, Email, Phone) and stores it in a SQLite database. The function should return the Flask application instance. The function should be named `create_flask_app`.
  assert create_flask_app() is not None
output: def create_flask_app():
      from flask import Flask, request, render_template
      import sqlite3
  
      app = Flask(__name__)
  
      def init_db():
          conn = sqlite3.connect('data.db')
          cursor = conn.cursor()
          cursor.execute('''
              CREATE TABLE IF NOT EXISTS contacts (
                  id INTEGER PRIMARY KEY AUTOINCREMENT,
                  name TEXT NOT NULL,
                  email TEXT NOT NULL,
                  phone TEXT NOT NULL
              )
          ''')
          conn.commit()
          conn.close()
  
      @app.route('/', methods=['GET', 'POST'])
      def index():
          if request.method == 'POST':
              name = request.form['name']
              email = request.form['email']
              phone = request.form['phone']
              conn = sqlite3.connect('data.db')
              cursor = conn.cursor()
              cursor.execute('INSERT INTO contacts (name, email, phone) VALUES (?, ?, ?)', (name, email, phone))
              conn.commit()
              conn.close()
          return render_template('form.html')
  
      init_db()
      return app