input: Write a function to generate a machine learning model using scikit-learn for classifying digits in the MNIST dataset. The function should load the dataset, split it into features and labels, create and fit a Logistic Regression classifier, and return the classifier. If the input dataset is not available, the function should raise a ValueError.
  assert type(create_mnist_classifier())==type(LogisticRegression())
  assert create_mnist_classifier().score(X, y)>0.8
output: def create_mnist_classifier():
      from sklearn.datasets import fetch_openml
      from sklearn.linear_model import LogisticRegression
      from sklearn.model_selection import train_test_split
  
      try:
          mnist = fetch_openml('mnist_784')
      except Exception:
          raise ValueError("MNIST dataset is not available.")
  
      X, y = mnist.data, mnist.target
      X_train, _, y_train, _ = train_test_split(X, y, test_size=0.2, random_state=42)
  
      classifier = LogisticRegression(max_iter=2000)
      classifier.fit(X_train, y_train)
  
      return classifier